Бурдюгова Мария, 321 HalfMore 1465
Stanislav HalfMore 1665
t1def find_majority_element():t1def find_majority_element():
2    candidate = None2    candidate = None
3    count = 03    count = 0
4    while (item := input()):4    while (item := input()):
5        if count == 0:5        if count == 0:
6            candidate = item6            candidate = item
7            count = 17            count = 1
8        elif item == candidate:8        elif item == candidate:
9            count += 19            count += 1
10        else:10        else:
11            count -= 111            count -= 1
12    return candidate12    return candidate
13print(eval(find_majority_element()))13print(eval(find_majority_element()))
Legends
Colors
 Added 
Changed
Deleted
Links
(f)irst change
(n)ext change
(t)op