Шагов Виталий 521 HalfMore 1543 | Антон Карлстедт, 321 HalfMore 1245 | ||||
---|---|---|---|---|---|
n | 1 | s = 0 | n | 1 | amount = 0 |
2 | res = None | 2 | obj = None | ||
3 | while (x := input()): | 3 | while (s := input()): | ||
4 | x = eval(x) | 4 | s = eval(s) | ||
5 | if s == 0: | 5 | if amount == 0: | ||
6 | res = x | 6 | obj = s | ||
7 | s += 1 | 7 | amount += 1 | ||
8 | if x == res: | 8 | elif obj == s: | ||
9 | s += 1 | 9 | amount += 1 | ||
10 | else: | 10 | else: | ||
t | 11 | s -= 1 | t | 11 | amount -= 1 |
12 | print(res) | 12 | print(obj) |
Legends | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
|