#include #define F(i,n) for(int i = 0;i < n;i++) void x(const int a[],int a_c[],int n){for(int i = 0;i < n;i++) a_c[i] = a[i];} int y(const int a[],int n){int min,nb;min = a[0]; nb = 0;for(int i = 0;i < n;i++){if(min > a[i]) {min = a[i];nb = i;}}return(nb);} void z(const int a[],int b[],int n){int nb;int tmp[n];x(a,tmp,n);for(int i = 0;i < n;i++){nb = y(tmp,n);b[i] = tmp[nb];tmp[nb] = 1000000000;}} int main(void){ int n,r=0; scanf("%d",&n); int a[n+2]; F(i,n)scanf("%d",&a[i]); z(a,a,n); for(int i=1;i