
数据结构源码实现#严奶奶版本
关于数据结构严奶奶版本源码实现,
部分源码由于是个人喜好问题,代码风格不同于数据结构定义的格式。
JAT9321
这个作者很懒,什么都没留下…
展开
-
数据结构》严奶奶版本---线性表(1)单链表 完整源码
顺序表(1)单链表 完整源码//单链表/*2)在递增有序单链表L上增加一个元素x,使之仍然保持有序;3)在单链表L上查找值为x的元素,若找到,p指向值为X的结点,若没找到,p为空;4)在递增有序单链表L上删除大于mink小于maxk的元素;5)在有序单链表L上删除多余的相同元素*/#include <iostream>#include <windows.h>using namespace std;typedef char ElemType; //存储的数据类原创 2020-06-02 15:05:50 · 206 阅读 · 0 评论 -
数据结构》严奶奶版本---线性表(2)顺序表 完整源码
数据结构—线性表(2)顺序表 完整源码//顺序表#include <iostream>#include <stdlib.h>#include <windows.h>using namespace std;//初始化储存的元素个数#define INIT_SIZE 10//增长因子 每次增长为原来的两倍#define ADD_TWICE 2 //存储的元素类型typedef int ElemType;//顺序表的存储结构typedef s原创 2020-06-06 12:01:21 · 253 阅读 · 0 评论 -
数据结构》严奶奶版本---线性表(3)双循环链表 完整源码
数据结构—线性表(3)双链表 完整源码/*1)在双向循环链表上实现插入、删除操作;*/#include <iostream>#include <windows.h>using namespace std;typedef int ElemType;typedef struct Dlinklist{ ElemType data; struct Dlinklist *prior; struct Dlinklist *next;}DNode,*DLinkL原创 2020-06-09 15:21:12 · 149 阅读 · 0 评论 -
数据结构》严奶奶版本---栈(1) 顺序栈 完整源码
数据结构》严奶奶版本—栈(1) 顺序栈 完整源码//顺序栈#include <iostream>#include <windows.h>#include <string>using namespace std;#define STACK_INIT_SIZE 100#define STACK_ADD_SIZE 10typedef int SElemType;typedef struct sqstack{ SElemType* top; SE原创 2020-06-14 21:36:47 · 226 阅读 · 0 评论 -
数据结构》严奶奶版本---栈(2) 链栈 完整源码
数据结构》-栈(2) 链栈 完整源码#include <iostream>#include <windows.h>using namespace std;typedef int LElemType;typedef struct Lnode{ LElemType data; struct Lnode* next;}LNode,*LinkList;typedef struct Lstack{ LinkList top; LinkList base;.原创 2020-06-17 20:11:14 · 311 阅读 · 0 评论 -
数据结构》严奶奶版本---队列(1) 链队列 完整源码
数据结构》队列(1) 链队列 完整源码//链队列#include <iostream>#include <windows.h>#include <string>#include "main.h"using namespace std;typedef char ElemType;typedef struct qnode{ ElemType data; struct qnode *next;}QueueNode,*QNode;typ.原创 2020-06-19 21:58:35 · 213 阅读 · 0 评论 -
数据结构》严奶奶版本---队列(2) 循环队列 完整源码
数据结构》队列(2) 循环队列 完整源码//循环队列#include <iostream>#include <windows.h>using namespace std;#define MAX_SIZE 10typedef int ElemType;typedef struct squeue{ ElemType *data; int front; int rear;}SqQueue;bool init_queue(SqQueue &am.原创 2020-06-22 18:26:16 · 180 阅读 · 0 评论 -
数据结构》严奶奶版本---队列(3) 舞伴问题 完整源码
数据结构》-队列(3) 舞伴问题 完整源码#include <iostream>#include <windows.h>#include <string>using namespace std;typedef struct person{ string name; char sex;}Person;typedef Person ElemType;//循环队列#define MAX_SIZE 10typedef struct s.原创 2020-06-22 18:29:15 · 681 阅读 · 0 评论 -
数据结构》严奶奶版本---树(1)二叉树 完整源码
数据结构》严奶奶版本—树(1)二叉树 完整源码//二叉树#include <iostream>#include <windows.h>#include <string>using namespace std;#define MAX_SIZE 100typedef char ElemType;//二叉树结构定义typedef struct btnode{ ElemType data; struct btnode *lchild; s.原创 2020-06-29 21:46:27 · 315 阅读 · 0 评论 -
数据结构》严奶奶版本---树(2)中序二叉树 完整源码
数据结构》树(2)中序二叉树 完整源码//中序线索二叉树#include <iostream>#include <windows.h>using namespace std;typedef char ElemType;//定义枚举类型 link 0 tread 1typedef enum{ link, thread}pointertag;//定义树的结构类型typedef struct mtnode{ ElemType data; .原创 2020-06-29 21:52:05 · 146 阅读 · 0 评论 -
数据结构》严奶奶版本---树(3)树 完整源码
数据结构》树(3)树 完整源码//树#include <iostream>#include <windows.h>using namespace std;#define MAXSIZE 100typedef char ElemType;//树的孩子兄弟链表定义typedef struct csnode{ ElemType data; struct csnode *firstchild; struct csnode *nextsibling;}CS原创 2020-06-29 21:55:13 · 334 阅读 · 0 评论 -
数据结构》严奶奶版本---图(1) 图的基础操作及应用 完整源码
图的基础操作及应用 完整源码//图的存储结构//邻接矩阵、邻接表#include <iostream>#include <windows.h>#include <iomanip>using namespace std;#define MAXINT 65535#define MAX_VERTEX_NUM 100#define STACK_INIT_SIZE 100#define STACK_ADD 10typedef char InfoT.原创 2020-06-30 15:35:03 · 604 阅读 · 0 评论