• 2022-06-05
    设指针变量p指向双向链表中结点A,指针变量s指向被插入的结点X,则在结点A的后面插入结点X的操作序列为()。
    A: p->next=s;s->prior=p;p->next->prior=s;s->next=p->next;
    B: s->prior=p;s->next=p->next;p->next=s;p->next->prior=s;
    C: p->next=s;p->next->prior=s;s->prior=p;s->next=p->next;
    D: s->prior=p;s->next=p->next;p->next->prior=s;p->next=s;
  • 举一反三