1.冒泡排序:
int a[10];
cin>>a;
for(int j=0;j<strlen(a)-1;j++)
for(int i=0;i<strlen(a)-1-j;i++)
if(a[i]>a[i+1]){
int tmp=a[i];
a[i]=a[i+1];
a[i+1]=tmp;
}