Untitled

 avatar
unknown
python
4 years ago
204 B
7
Indexable
age=int(input())
max1=age
max2=age
while age!=-1:
    age=int(input())
    if age>max1:
        max2=max1
        max1=age
    else:
        if age>max2:
            max2=age
print(max1,max2)
Editor is loading...