- 博客(5)
- 收藏
- 关注
原创 二叉树的先序,中序,后序遍历 c语言
#include #include #define Data_Type char typedef struct Node{ Data_Type data; Node * lchird; Node * rchird; }NODE, *PNODE; PNODE create(); void preOrderTraverse(PNODE); void inOrderTraverse(PNOD
2015-08-10 13:29:45 2576
原创 链表实现队列 c语言
#include #include #include #define Data_Type int typedef struct Node{ Data_Type data; struct Node * pNext; }NODE,*PNODE; typedef struct LinkQueue{ //first node PNODE front; //lash node PNODE r
2015-08-07 18:22:23 911
原创 静态数组实现循环队列 c语言
#include #include #define Data_Type int #define Queue_Len 5 //判断队满有两种方式,一种是加以个标记,比如说size。 //另一种是浪费一块空间,当占到N-1时,就算满。 typedef struct Queue{ Data_Type data[Queue_Len]; int front;//队头元素的前一个元素 int re
2015-08-05 00:40:38 2409
原创 链表实现链式栈 c语言
#include #include #define Data_Type int typedef struct Stack{ //必须pBottom做头,否则将无法删除 struct Node * pBottom; struct Node * pTop; }STACK,* PSTACK; typedef struct Node{ Data_Type data; struct Node
2015-08-02 18:00:08 470
原创 利用静态数组实现栈 c语言
#include #include //栈的大小 #define MaxSize 10 //数据类型 #define STACK_TYPE int typedef struct Stack{ STACK_TYPE data[MaxSize]; int top; }STACK,* PSTACK; //是否为空 bool isEmpty(PSTACK); //是否满 bool isFull
2015-08-02 01:10:20 540
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人