import Control.Applicative

quicksort :: [Int] -> [Int]
quicksort [] = []
quicksort (x:xs) = (quicksort gt) ++ [x] ++ (quicksort lteq)
  where gt = [a | a <- xs, a > x]
        lteq = [a | a <- xs, a <= x]

addSpace :: String -> String
addSpace [c] = [c] ++ " "

main = do
  n <- fmap (read :: String -> Int) . words <$> getContents
  mapM putStr $ fmap (addSpace . show) (quicksort n)