Что выведет программа mx = int(input()) mx2 = int(input()) if (mx2 > mx): mx2 = mx2 + mx mx = mx2 - mx mx2 = mx2 - mx while 1: x = int(input()) if x == 0: break elif x >= mx: mx2 = mx mx = x elif x > mx2: mx2 = x print(mx2) при вводе 1 9 2 3 4 5 6 7 8 10 0
Задание

Что выведет программа
mx = int\(input\(\))
mx2 = int\(input\(\))
if \(mx2 \\gt mx\):
mx2 = mx2 + mx
mx = mx2 - mx
mx2 = mx2 - mx
while 1:
x = int\(input\(\))
if x == 0:
break
elif x >= mx:
mx2 = mx
mx = x
elif x > mx2:
mx2 = x
print\(mx2\)

при вводе
1
9
2
3
4
5
6
7
8
10
0