ListNode* ReverseList(ListNode* pHead) { ListNode *p1,*p2,*p3; p1=NULL; p2=pHead; while(p2){ p3=p2->next; p2->next=p1; p1=p2; p2=p3; } return p1; }