随笔分类 -  数据结构c语言版

6.带头结点的单链表操作
摘要:#include<stdio.h>#include<stdlib.h>typedef int ElemType; typedef struct LNode{ ElemType data; struct LNode *next; }LNode,*LinkList;LNode * GetElem(Lin 阅读全文
posted @ 2021-06-15 21:47 upupup-999 阅读(116) 评论(0) 推荐(0)
5.顺序表的按位和按值查找
摘要:#include <stdio.h>#include <stdlib.h>#define InitSize 10 typedef int ElemType;typedef struct{ int *data; int MaxSize; int length;}SqList; void InitLis 阅读全文
posted @ 2021-06-14 21:08 upupup-999 阅读(320) 评论(0) 推荐(0)
4.顺序表的删除
摘要:#include <stdio.h>#define MaxSize 10typedef int ElemType;typedef struct{ int data[10]; int length;}SqList; void InitList(SqList &L){ for(int i=0;i<Max 阅读全文
posted @ 2021-06-14 20:04 upupup-999 阅读(62) 评论(0) 推荐(0)
3.顺序表的插入
摘要:#include <stdio.h>#define MaxSize 10typedef int ElemType;typedef struct{ int data[10]; int length;}SqList; void InitList(SqList &L){ for(int i=0;i<Max 阅读全文
posted @ 2021-06-14 18:36 upupup-999 阅读(260) 评论(0) 推荐(0)
2.顺序表的定义(动态)
摘要:#include <stdio.h>#include <stdlib.h>#define InitSize 10 typedef int ElemType;typedef struct{ int *data; int MaxSize; int length;}SqList; void InitLis 阅读全文
posted @ 2021-06-14 17:36 upupup-999 阅读(85) 评论(0) 推荐(0)
1.顺序表的定义
摘要:#include <stdio.h>#define MaxSize 10typedef int ElemType;typedef struct{ int data[10]; int length;}SqList; void InitList(SqList &L){ for(int i=0;i<Max 阅读全文
posted @ 2021-06-14 17:35 upupup-999 阅读(69) 评论(0) 推荐(0)