此函数有什么问题吗?
xn_hv 2006-06-18 01:33:35
此函数有什么问题吗?
void Taxis(struct student students[],int amount)
{ int i,j;
struct student temp;
for(i = 0; i < amount; i++)
for(j = i+1; j < amount; j++)
if(students[i].sum < students[j].sum)
{temp = students[i];
students[i] = students[j];
students[j] = temp;
}
}