链表求中间值问题

来源:互联网 发布:彩票概率软件 编辑:程序博客网 时间:2024/04/27 21:14
void searchmid(node* head,node*mid ){node *temp=head;
  
while(head->next->next!=NULL){head=head->next->next;
  mid
=temp;
  temp
->temp->next;
   
}
}