Submission #1103700

#TimeUsernameProblemLanguageResultExecution timeMemory
1103700zephyrionTuna (COCI17_tuna)Cpython 3
50 / 50
14 ms2896 KiB
n = int(input()) x = int(input()) ans = 0 for i in range(n): p1, p2 = map(int, input().split()) if abs(p1 - p2) <= x: ans += max(p1, p2) else: ans += int(input()) print(ans)
#Verdict Execution timeMemoryGrader output
Fetching results...