
数据结构
文章平均质量分 74
ai309581115
Swift开发1年工作经验IOS2年工作经验
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
栈的实现
#include#include#include#include#define VARTYPE char //默认存放char类型using namespace std;struct myNode;typedef struct myNode Node;typedef Node* _Stack;typedef Node* PtrToNode;struct myNode{原创 2014-09-20 21:42:15 · 448 阅读 · 0 评论 -
链式队列实现
#include#include#include#include#define VARTYPE char //默认存放char类型using namespace std;struct myNode;struct myQueue;typedef struct myNode Node;typedef Node* List;typedef Node* PtrToNode;原创 2014-09-21 00:10:03 · 336 阅读 · 0 评论 -
数组模拟队列和栈
#include#include#include#includeusing namespace std;#define VARTYPE char //默认存放char类型#define MAX 1000;//数组模拟栈VARTYPE _stack[MAX];int head = -1;void pop(){ head--;}void push(VARTYP原创 2014-09-21 00:31:25 · 454 阅读 · 0 评论 -
hihocoder 1049 后续遍历
#include#include#include#include#includeusing namespace std;char preorder[30],midorder[30],endorder[30];typedef struct mynode Node;typedef Node* Tree;struct mynode{ char data; stru原创 2014-10-12 17:47:00 · 582 阅读 · 0 评论 -
自己实现C语言双向向链表
#include#include#include#include#include#define CHAR char#define VARTYPE CHAR //默认存放char类型using namespace std;struct myNode;typedef struct myNode Node;typedef Node* List;typedef Node* Ptr原创 2014-09-20 17:45:35 · 452 阅读 · 0 评论 -
自己实现C语言单向链表
#include#include#include#include#define CHAR char#define VARTYPE CHARusing namespace std;struct myNode;typedef struct myNode Node;typedef Node* List;typedef Node* PtrToNode;struct myNo原创 2014-09-20 15:35:39 · 487 阅读 · 0 评论 -
二叉树先序,中序,后序遍历非递归实现
#include #include #include #include #include #include using namespace std;typedef struct BiTNode{ char data; BiTNode *lchild, *rchild;}BiTNode,*BiTree;void CreateBiTree(BiTree &T)//建树,按先序转载 2014-09-20 10:45:01 · 480 阅读 · 0 评论