arr = []
for i in range (10):
    arr.append(int(input()))
arr.sort()
arr.reverse()
for a in range (3):
    print(arr[a]) arr = [] arr [] for i in range (10):
    arr.append(int(input())) i range (10) range 10 arr.append(int(input())) arr.append arr append int(input()) int input() input arr.sort() arr.sort arr sort arr.reverse() arr.reverse arr reverse for a in range (3):
    print(arr[a]) a range (3) range 3 print(arr[a]) print arr[a] arr a arr = [] [] arr
arr = []
for i in range (10):
    arr.append(int(input()))
arr.sort()
arr.reverse()
for a in range (3):
    print(arr[a])