void reverse(test *heap) { test *pe=heap; test *ps=head->next; while(ps) { pe->next=ps->next; ps->next=head; head=ps; ps=pe->next; } } 转载于:https://blog.51cto.com/4893836/1024812