object Main extends App {

  val k = 10000

  def countingSort(A: Array[Int]): Array[Int] = {
    val C = new Array[Int](k + 1)

    for (e <- A)
      C(e) = C(e) + 1

    for (i <- 1 to k)
      C(i) = C(i) + C(i - 1)

    val B = new Array[Int](A.size)
    for (e <- A) {
      B(C(e) - 1) = e
      C(e) = C(e) - 1
    }

    B
  }

  val sc = new java.util.Scanner(Console.in)

  def readInt() = sc.next().toInt

  val ary = Array.fill(readInt())(readInt())
  println(countingSort(ary) mkString " ")
}

