typedef struct ListNode Node;

struct ListNode* ReverseList(struct ListNode* pHead ) {
    int i;
    Node* pPre = NULL;
    Node* pStart = pHead;
    Node* pTemp = NULL;
    if(!pHead||!(pHead->next))
        return pHead;
    while(pStart->next!=NULL)
    {
        pTemp = pStart->next;
        
        pStart->next=pPre;
        
        pPre = pStart;
        
        pStart=pTemp;
    }
    pStart->next = pPre;
    
    return pStart;
}