# coding: utf-8

#Name: List of Top 3 Hills
#Level: 1
#Category: ????????????
#Note:

s = [int(raw_input()) for i in range(10)]

s.sort()

for i in range(3):
    print s[9-i] int(raw_input()) for i in range(10) for i in range(10) i range(10) range 10 for i in range(10) int(raw_input()) int raw_input() raw_input s = [int(raw_input()) for i in range(10)] s [int(raw_input()) for i in range(10)] s.sort() s.sort s sort for i in range(3):
    print s[9-i] i range(3) range 3 print s[9-i] s 9-i 9 i s = [int(raw_input()) for i in range(10)] [int(raw_input()) for i in range(10)] s
# coding: utf-8

#Name: List of Top 3 Hills
#Level: 1
#Category: ????????????
#Note:

s = [int(raw_input()) for i in range(10)]

s.sort()

for i in range(3):
    print s[9-i]