![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
data structure
文章平均质量分 76
sky@sea
这个作者很懒,什么都没留下…
展开
-
C++栈实现不同进制之间转换
#include using namespace std; #define STACK_INIT_SIZE 100 #define STACKINCREMENT 10 typedef int SElemType; //定义栈结构 typedef struct { SElemType *base; SElemType *top; int stacksize; }SqStack; //建原创 2017-07-12 14:01:37 · 1011 阅读 · 0 评论 -
c++实现双向链表的建立,插入,删除,合并,打印
#include #include using namespace std; //双向链表的节点结构 typedef struct DuLNode{ int data; struct DuLNode *prior; struct DuLNode *next; }DuLNode, *DuLinkList; //创建双向链表 void Create_DuList(DuLinkList原创 2017-08-16 16:55:13 · 1468 阅读 · 0 评论 -
c++实现简单选择排序
#include #include using namespace std; #define LIST_INIT_SIZE 100 #define LISTINCREMENT 10 #define ElemType int typedef struct{ ElemType *elem; int length; int listsize; }SqList; //建顺序表 void Ini原创 2017-07-21 16:46:10 · 341 阅读 · 0 评论 -
c++实现快速排序
#include #include using namespace std; #define LIST_INIT_SIZE 100 #define LISTINCREMENT 10 #define ElemType int typedef struct{ ElemType *elem; int length; int listsize; }SqList; //打印 void Print原创 2017-07-21 16:45:29 · 310 阅读 · 0 评论 -
c++实现直接插入排序
#include #include using namespace std; #define LIST_INIT_SIZE 100 #define LISTINCREMENT 10 #define ElemType int typedef struct{ ElemType *elem; int length; int listsize; }SqList;原创 2017-07-21 16:41:37 · 447 阅读 · 0 评论 -
c++实现希尔排序
#include #include using namespace std; #define LIST_INIT_SIZE 100 #define LISTINCREMENT 10 #define ElemType int typedef struct{ ElemType *elem; int length; int listsize; }SqList;原创 2017-07-21 16:42:20 · 407 阅读 · 0 评论 -
c++实现顺序查找,折半查找
#include #include using namespace std; #define LIST_INIT_SIZE 100 #define LISTINCREMENT 10 #define ElemType int typedef struct{ ElemType *elem; int length; int listsize; }SqList; //建顺序表 void Ini原创 2017-07-21 16:40:24 · 3531 阅读 · 1 评论 -
循环队列的实现,插入,删除,打印,求长度
#include #define MAXSIZE 10 #define OK 1 #define ERROR 0 using namespace std; typedef int QElemType; //定义循环队列结构 typedef struct { QElemType *base; //初始化的动态分配存储空间 int front; //头指针,若队列不为空,指向队头元素 in原创 2017-07-21 16:36:51 · 5794 阅读 · 3 评论 -
顺序表的实现,插入,删除,定位,合并,打印
#include #include using namespace std; #define LIST_INIT_SIZE 100 #define LISTINCREMENT 10 #define ElemType int typedef struct{ ElemType *elem; int length; int listsize; }SqList; //建顺序表 void Ini原创 2017-07-21 16:38:21 · 1289 阅读 · 0 评论 -
单链队列的建立,插入,删除,打印,销毁
#include #define MAZSIZE 100 #define OK 1 #define ERROR 0 using namespace std; typedef int QElemType; //------------定义节点结构------------- typedef struct QNode { QElemType data; struct QNode *next; }原创 2017-07-21 16:34:38 · 966 阅读 · 1 评论 -
c++实现栈建立,插入,删除
# include using namespace std; #define STACK_INIT_SIZE 10 #define STACKINCREMENT 5 typedef int SElemType; //定义栈结构 typedef struct { SElemType *base; SElemType *top; int stacksize; }SqStack; //建立栈原创 2017-08-16 16:59:36 · 2181 阅读 · 0 评论