object Main App {
  val n: Int = io.StdIn.readLine().toInt
  val arr: Array[Int] = io.StdIn.readLine().split(" ") map(_.toInt)

  val maxVal: Int = 10000
  val count: Array[Int] = Array.fill(maxVal+1)(0)
  val result: Array[Int] = Array.fill(n)(0)

  for (i <- arr) count(i) += 1
  for (i <- 1 to arr.length) count(i) += count(i-1)

  for (i <- n-1 to 0 by -1) {
    result(count(arr(i))-1) = arr(i)
    count(arr(i)) -= 1
  }

  println(result.mkString(" "))
}