Runtime error due to condtion in while loop of finding mid element in linked list

前端 未结 0 1158
南方客
南方客 2021-01-02 16:31
Node* findMid(Node *head) {
   if(head == NULL || head -> next == NULL) 
        return head;
   Node *slow = head;
   Node *fast = head;
   while(fast &&         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题