• 2022-07-29
    在循环双链表的p所指结点之后插入s所指结点的操作是_____。
    A: p->right=s; s->left=p; p->right->left=s; s=->right=p->right;
    B: p->right=s; p->right->left=s; s->left=p; s->right=p->right;
    C: s->left=p; s->right= p->right; p->right=s; p->right->left=s;
    D: s->left=p; s->right=p->right; p->right->left=s; p->right=s;
  • D

    举一反三

    内容

    • 0

      在循环双链表的p所指结点之后插入s结点的操作是( ) A: p->next=s; s->pre=p; p->next->pre=s; s->next=p->next; B: p->next=s; p->next->pre=s; s->pre=p; s->next=p->next; C: s->pre=p; s->next=p->next; p->next->pre=s; p->next=s; D: s->pre=p; s->next=p->next; p->next=s; p->next->pre=s;

    • 1

      在循环双链表的P所指节点之后插入s所指节点的操作是( ) A: p->next=s; s->prior=p; p->next->prior=s; s->next=p->next; B: p->next=s; p->next->prior=s; s->prior=p; s->next=p->next; C: s->prior=p; s->next=p->next; p->next=s; p->next->prior=s; D: s->prior=p; s->next=p->next; p->next=s;p->next->prior=s;

    • 2

      在循环双链表的p所指的结点之前插入s所指结点的操作是 ( ) A: p->;prior = s;s->;next = p;p->;prior->;next = s;s->;prior = p->;prior; B: p->;prior = s;p->;prior->;next = s;s->;next = p;s->;prior = p->;prior; C: s->;next = p;s->;prior = p->;prior;p->;prior = s;p->;prior->;next = s; D: s->;next = p;s->;prior = p->;prior;p->;prior->;next = s;p->;prior = s;

    • 3

      在一个单链表中,若p所指结点不是最后结点,在p所指结点之后插入s所指结点,则应执行()操作。 A: s->link=p;p->link=s; B: s->link=p->link:p->link=s: C: S->link=p->link; p=s: D: p->link=s:s->link=p:

    • 4

      在一个单链表中,若p所指节点不是最后节点,在p之后插入s所指节点,则执行()。 A: s->next=p;p->next=s; B: s->next=p->next;p->next=s; C: s->next=p->next;p=s; D: p->next=s;s->next=p;