Стрелов Глеб Сергеевич
12.10.2019 17:43 (0:05) [2718314]
k = int(input()) res = 0 for i in range(k): if res < 1000: res += int(input()) print(res)