void fun(struct student a[], int n)
{ //请完善该部分代码
int i, j;
for(i = 0; i < n - 1; i++)
for(j = 0; j < n - 1 - i; j++)
if(strcmp(a[j].name , a[j + 1].name) > 0) {
struct student tmp = a[j];
a[j] = a[j + 1];
a[j + 1] = tmp;
}
}
void fun(struct student a[], int n)
{ //请完善该部分代码
int i, j;
for(i = 0; i < n - 1; i++)
for(j = 0; j < n - 1 - i; j++)
if(strcmp(a[j].name , a[j + 1].name) > 0) {
struct student tmp = a[j];
a[j] = a[j + 1];
a[j + 1] = tmp;
}
}