{-# LANGUAGE BangPatterns #-}
import Control.Monad
import Data.Maybe
import Debug.Trace
import Data.List
import qualified Data.Map.Strict as Map
import qualified Data.IntMap.Strict as IntMap
import qualified Data.Set as Set
import qualified Data.IntSet as IntSet
import Data.Functor

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

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, n) -> replicate n i) $ IntMap.assocs c
  where
    c = foldr f IntMap.empty as
    f :: Int -> IntMap.IntMap Int -> IntMap.IntMap Int
    f !k dic = IntMap.insertWith (+) k 1 dic

