import sys



def countingSort(A, B, k):

    C = [0] * (k + 1)



    for j in range(0, len(A)):

        C[A[j]] += 1



    for i in range(1, k + 1):

        C[i] += C[i - 1]



    B = [0] * (max(C) + 1)

    for j in range(len(A) - 1, -1, -1):

        B[C[A[j]]] = A[j]

        C[A[j]] -= 1



    del B[0]

    print(" ".join([str(b) for b in B]))



if __name__ == "__main__":

    lines = sys.stdin.readlines()

    A = list(map(int, lines[1].split()))

    B = []

    countingSort(A, B, max(A))
import sys



'''

def countingSort(A, B, k):

    C = [0] * (k + 1)



    for j in range(len(A)):

        C[A[j]] += 1



    for i in range(1, k + 1):

        C[i] += C[i - 1]



    B = [0] * (max(C) + 1)

    for j in range(len(A) - 1, -1, -1):

        B[C[A[j]]] = A[j]

        C[A[j]] -= 1



    del B[0]

    print " ".join([str(b) for b in B])

    '''



def countingSort(A, B, k):

    C = [0] * (k + 1)

    for i in range(len(A)):

        C[A[i]] += 1

    for i in range(len(C)):

        for j in range(C[i]):

            B.append(i)

    print(" ".join([str(b) for b in B]))



if __name__ == "__main__":

    lines = sys.stdin.readlines()

    A = list(map(int, lines[1].split()))

    B = []

    countingSort(A, B, 10000)
import sys


def countingSort(A, B, k):
    C = [0] * (k + 1)
    for j in range(0, len(A)):
        C[A[j]] += 1
    for i in range(1, k + 1):
        C[i] += C[i - 1]
    B = [0] * (max(C) + 1)
    for j in range(len(A) - 1, -1, -1):
        B[C[A[j]]] = A[j]
        C[A[j]] -= 1
    del B[0]
    print(" ".join([str(b) for b in B]))


if __name__ == "__main__":
    lines = sys.stdin.readlines()
    A = list(map(int, lines[1].split()))
    B = []
    countingSort(A, B, max(A))

import sys

"""
def countingSort(A, B, k):
    C = [0] * (k + 1)
    for j in range(len(A)):
        C[A[j]] += 1
    for i in range(1, k + 1):
        C[i] += C[i - 1]
    B = [0] * (max(C) + 1)
    for j in range(len(A) - 1, -1, -1):
        B[C[A[j]]] = A[j]
        C[A[j]] -= 1
    del B[0]
    print " ".join([str(b) for b in B])
    """


def countingSort(A, B, k):
    C = [0] * (k + 1)
    for i in range(len(A)):
        C[A[i]] += 1
    for i in range(len(C)):
        for j in range(C[i]):
            B.append(i)
    print(" ".join([str(b) for b in B]))


if __name__ == "__main__":
    lines = sys.stdin.readlines()
    A = list(map(int, lines[1].split()))
    B = []
    countingSort(A, B, 10000)

- +""" -    for j in range(0, len(A)): +    for j in range(len(A)): +    print " ".join([str(b) for b in B]) +    """ + + +def countingSort(A, B, k): +    C = [0] * (k + 1) +    for i in range(len(A)): +        C[A[i]] += 1 +    for i in range(len(C)): +        for j in range(C[i]): +            B.append(i) -    countingSort(A, B, max(A)) +    countingSort(A, B, 10000)