{-# OPTIONS_GHC -Wall -Werror #-}

import Control.Monad
import Data.List

readInt :: IO Int
readInt = readLn

main :: IO ()
main = do
  input <- replicateM 10 readInt
  mapM_ print (take 3 (sortBy (\x y -> compare y x) input))