typedef struct Node; { char name[20]; float gpa; Node *next; }; |
for( temp1 = head ; temp1!=NULL ; temp1 = temp1->next ) { for( temp2 = temp1->next ; temp2!=NULL ; temp2 = temp2->next ) { if( temp1->data > temp2->data ) { temp = temp1->data; temp1->data = temp2->data; temp2->data = temp; } } } |
char name[20]; float gpa; |
|
|