import scala.io.StdIn.{readInt, readLine}

object Main extends App {
  import CountingSort.countingSort

  val n  = readInt()
  val xs = readLine().split(' ').map { _.toInt }

  val ys = countingSort(xs)
  println(ys.mkString(" "))
}

object CountingSort {
  val MaxValue = 10000

  def countingSort(xs: Array[Int]): Array[Int] = {
    val counts = {
      val counts = Array.fill(MaxValue + 1)(0)
      for (x <- xs) {
        counts(x) += 1
      }

      var i = 1
      while (i <= MaxValue) {
        counts(i) = counts(i) + counts(i - 1)
        i += 1
      }

      counts
    }

    val ys = new Array[Int](xs.length)
    for (x <- xs) {
      ys(counts(x) - 1) = x
      counts(x) -= 1
    }

    ys
  }
}

