單項選擇題

若有以下定義

則不能將指針q所指的結(jié)點接到鏈表末尾的程序段是()。

A.q->next=NULL;p=p->next;p->next=q
B.p=p->next;q->next=p->next;p->next=q
C.p=p->next;q->next=p;p->next=q
D.p=(*p).next;(*q).next=(*p).next;(*p).next=q

微信掃碼免費搜題