n = gets.chomp.to_i
as = gets.chomp.split(' ').map(&:to_i)

cs = []
0.upto(10_000){|i| cs << 0}
as.each{|a| cs[a] += 1}
1.upto(cs.length - 1){|i| cs[i] += cs[i - 1]}
s = []
(as.length - 1).downto(0) do |i|
  s[cs[as[i]] - 1] = as[i]
  cs[as[i]] -= 1
end

puts s.join(' ')
