

list + map + split() 활용하여 입력받는다.list 첫 번째 인덱스는 학생 수이기때문에 [1:]로 슬라이싱한다.for 반복문 + if 조건문 + cnt라는 개수세는 변수 증감표현식으로 평균을 넘는 학생들을 구별한다..3f를 이용하여 소수점 셋째 자리 출력한다.%%를 이용하여 %를 출력한다.# boj, 4344 : 평균은 넘겠지, python3
import sys
C = int(sys.stdin.readline())
cnt = 0
for i in range(C):
N_score = list(map(int,sys.stdin.readline().split()))
average = sum(N_score[1:]) // N_score[0]
for j in N_score[1:]:
if average < j:
cnt += 1
print("%.3f%%"%((cnt/N_score[0])*100))
cnt = 0

https://www.acmicpc.net/problem/4344