import java.util.Arrays; import java.util.PriorityQueue; import java.util.Scanner; public class Main { public static void main(String[] args) { new Main().run(); } void run() { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); int[] a = new int[n]; for (int i = 0; i < n; ++i) { a[i] = sc.nextInt(); } for (int i = 1; i < 2 * n - 3; ++i) { int s = 0; int t = i; while (t - s > 1) { if (t < n && a[s] > a[t]) { int d = a[s]; a[s] = a[t]; a[t] = d; } ++s; --t; } } for (int i = 0; i < n; ++i) { System.out.print(a[i] + (i == n - 1 ? "\n" : " ")); } } static void tr(Object... objects) { System.out.println(Arrays.deepToString(objects)); } }