import Data.List
import Control.Monad
main :: IO()
main = do
  inputs <- replicateM 10 getLine
  let tops = take 3 . reverse . sort $ map (\x -> read x :: Int) inputs
  putStrLn $ intercalate "\n" $ map show tops