//Insertion sort
#include <stdio.h>
#include <iostream>
using namespace std;
typedef int status;
int main()
{
status a[100];
int n;
while(scanf("%d",&n) != EOF){
int i, j;
status key;
for(i=0; i<n; i++)
cin>>a[i];
for(j=1; j<n; j++)
{
key = a[j];
i = j-1;
while(i>=0 && a[i+1] < a[i]) //ascending order
// descending order ---> while(i && a[i+1] > a[i])
{
a[i+1] = a[i];
i--;
}
a[i+1] = key;
}
for(i=0; i<n; i++)
if(i == n-1)
cout<<a[i]<<endl;
else
cout<<a[i]<<" ";
}
return 0;
}