#include<stdio.h>
#include<string.h>
char *maopaofa(char *s) //冒泡法
{
char temp;
int i,j,k;
i=strlen(s);
k=i;
for(i=0;i<(k-1);i++)
{
for(j=0;j<(k-i-1);j++)
{
if(*s-*(s+1)>0)
{
temp=*s;
*s=*(s+1);
*(s+1)=temp;
}
s++;
}
s=s-(k-i)+1;
}
return s;
}
void bashiyi(void)
{
char a[20];
printf("输入个字符串:/n");
gets(a);
puts(maopaofa(a));
printf("/n");
}