#include<stdio.h>
#include<stdlib.h>
#define MAXLEN 20000001
#define VMAX 10000

void CountingSoat(unsigned short *, unsigned short *, int);

unsigned short *A, *B;
int n;

int main(){
  int i, j;
  short max=0;

  scanf("%d", &n);

  A = malloc(sizeof(short)*n+1);
  B = malloc(sizeof(short)*n+1);
  for(i=0; i<n; i++){
    scanf("%hd", &A[i]);
    //if(A[i] > max) max = A[i];
  }
  
  CountingSoat(A, B, VMAX);
  for(i=1; i<n; i++){
    printf("%d ", B[i]);
  } printf("%d\n", B[i]);

  free(A);
  free(B);
  return 0;
}

void CountingSoat(unsigned short *A, unsigned short *B, int max){
  
  int i, j;
  short C[VMAX+1];
  for(i=0; i<VMAX; i++){
    C[i] = 0;
  }
  //printf("⊂二二二（ ＾ω＾）二⊃ ﾌﾞｰﾝ\n");

  for(j=0; j<n; j++){
    C[A[j]]++;
  }
  //printf("⊂二二二（ ＾ω＾）二⊃ ﾌﾞｰﾝ\n");

  /*
  for(i=0; i<n-1; i++){
    printf("%d ", C[i]);
  } printf("%d\n", C[i]);
  */
  
  for(i=1; i<=VMAX; i++){
    C[i] = C[i] + C[i-1];
  }
  /*
  for(i=0; i<n-1; i++){
    printf("%d ", C[i]);
  } printf("%d\n", C[i]);
  */
  //printf("⊂二二二（ ＾ω＾）二⊃ ﾌﾞｰﾝ\n");

  for(j=0; j<=n; j++){
    B[C[A[j]]] = A[j];
    C[A[j]]--;
  }
  //printf("⊂二二二（ ＾ω＾）二⊃ ﾌﾞｰﾝ\n");
}

