본문 바로가기
Beakjoon&프로그래머스/파이썬

[백준/파이썬] 30791번 gahui and sousenkyo 1

by 현장 2023. 12. 5.

-Code

votes = list(map(int, input().split()))
rank = votes[0]
res = 0

for v in votes[1:]:
    if rank - v <= 1000:
        res += 1

print(res)