Untitled

mail@pastecode.io avatar
unknown
python
2 years ago
204 B
3
Indexable
Never
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)