- 8
- 0
- 约1.85千字
- 约 17页
- 2017-06-15 发布于河南
- 举报
数据结_第2章-3双向链表
六、双向链表;;2、双向链表的操作实现;;例:已知P结点是双向链表的中间结点,试从下列提供的答案中选择合适的语句序列。;(1)P-next=P-next-next; (10) P-prior-next=P;
(2)P-prior=P-prior-prior; (11) P-next-prior =P;
(3) P-next=S; (12)P-next-prior=S;
(4) P-prior=S; (13) P-prior-next=S;
(5)S-next=P; (14) P-next-prior=P-prior
(6)S-prior=P; (15)Q=P-next;
(7) S-next= P-next; (16)Q= P-prior;
(8) S-prior= P-prior; (17)free(P);
(9) P-prior-next=p-next; (18)free(Q);
;2.4 静态链表; 静态单链表的类型定义如下:
#define MAXSIZE 1000 //预分配最大的元素个数(连续空间
typedef struct {
原创力文档

文档评论(0)