在一个栈顶指针为top的链栈中,将一个p指针所指的结点人栈,应执行()。

在一个栈顶指针为top的链栈中,将一个p指针所指的结点人栈,应执行()。

A.top->next=p

B.p->next=top->next;top->next=p

C.p->next=top;top=p

D.p->next=top->next,top=top->next

正确答案:C

猜你喜欢