数据结构-循环链表基础操作
作者:互联网
1 循环双链表后插
bool InsertNextDNode(DNode *P, DNode *s){
s->next = p->next; //将结点*s插入到结点*p之后
p->next->prior = s;
s->prior = p;
p->next = s;
return ture;
}
2 循环双链表后删
bool DeleteNextDNode(DNode *p){
DNode *q = p;
p->next = q->next;
q->next->prior = p;
free(q);
return ture;
}
标签:return,next,链表,prior,循环,bool,表后,数据结构,DNode 来源: https://blog.csdn.net/rohee/article/details/119205139