{-# LANGUAGE BangPatterns #-}
import Control.Monad
import Data.Maybe
import Debug.Trace
import Data.List
import Data.Functor
-- import Data.Array
import Data.Array.Unboxed
import Control.Monad.ST
import Data.Array.ST

import qualified Data.ByteString.Char8 as B
import Data.Maybe (fromJust)
readInts = map (fst . fromJust . B.readInt) . B.words <$> B.getLine :: IO [Int]

main :: IO ()
main = do
  n <- readLn :: IO Int
  as <- readInts
  putStrLn . unwords . map show $ solve as

solve = countingSort (0, 10000)

countingSort :: (Int, Int) -> [Int] -> [Int]
countingSort (s,e) as = concatMap (\i -> replicate (carr ! i) i) [s..e]
  where
    carr :: UArray Int Int
    carr = runSTUArray $ do
      arr <- newArray (s,e) 0
      forM_ as (\a -> do
        val <- readArray arr a
        writeArray arr a (val + 1) 
        )
      return arr

