heights=[]
for i in range(0,10):
	heights.append(input())
heights.sort()
heights.reverse()
for i in range(0,3):
	print heights[i] heights=[] heights [] for i in range(0,10):
	heights.append(input()) i range(0,10) range 0 10 heights.append(input()) heights.append heights append input() input heights.sort() heights.sort heights sort heights.reverse() heights.reverse heights reverse for i in range(0,3):
	print heights[i] i range(0,3) range 0 3 print heights[i] heights i heights=[] [] heights
heights=[]
for i in range(0,10):
	heights.append(input())
heights.sort()
heights.reverse()
for i in range(0,3):
	print heights[i]