height1 = gets.chomp.to_i
height2 = gets.chomp.to_i
height3 = gets.chomp.to_i
height4 = gets.chomp.to_i
height5 = gets.chomp.to_i
height6 = gets.chomp.to_i
height7 = gets.chomp.to_i
height8 = gets.chomp.to_i
height9 = gets.chomp.to_i
height10 = gets.chomp.to_i
a=[height1, height2, height3, height4, height5, height6, height7, height8, height9, height10]
b=a.sort
puts b[9]
puts b[8]
puts b[7]