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

[백준/파이썬] 8725번 Szachy

by 현장 2025. 4. 2.

-Code

res = 0
for _ in range(int(input())):
    temp = max(list(map(int, input().split())))
    res += temp if temp > 0 else 0
print(res)