#include <iostream>
using namespace std;
int main()
{
    int n;
    cin >> n;
    int arr[n];

    for ( int i = 0 ; i < n ; i ++ )
    {
        cin >> arr[i];
    }

    int min = arr[0];
    for ( int x = 0 ; x < n - 1 ; x ++ )
    {
        for ( int d = 0 ; d < n ; d ++ )
        {
            if ( arr[d] < min && d > x ) 
            {
               swap ( arr[x] , arr[d] );
               min = arr[x];
            }  
        }
        min = arr[x + 1];
    }

    for ( int i = 0 ; i < n ; i ++ )
    {
        cout << arr[i] <<" ";
    }


    return 0;
}