phead 是头节点,ptail是尾节点,在编辑的时候 顺序不对,就会出错
如:phead -> next = ptail;ptail = phead;ptail -> next = NULL;可以运行,
但是一个语句交换位置后phead -> next = ptail;ptail -> next = NULL;ptail = phead;就会出错。求大神解答,谢谢。
https://zhidao.baidu.com/question/395449857.html