摘要: 1 #include 2 #include 3 #include 4 using namespace std; 5 #define FILENAME "E:\\FUSHI\\test.txt" 6 7 int main() 8 { 9 /* 10 新建文件... 阅读全文
posted @ 2016-01-12 18:44 Xbert 阅读(284) 评论(0) 推荐(0) 编辑
摘要: 1 #include 2 #include 3 #include 4 5 using namespace std; 6 7 char str[220]; //表达式字符串 8 int mat[][5]= 9 { 10 1,0,0,0,0, 11 1,0... 阅读全文
posted @ 2016-01-07 15:16 Xbert 阅读(250) 评论(0) 推荐(0) 编辑
摘要: 1 #include 2 #include 3 #include 4 5 using namespace std; 6 7 stack S; 8 char str[110]; 9 char ans[110];10 11 int main()12 {13 while(scanf("... 阅读全文
posted @ 2016-01-07 15:16 Xbert 阅读(196) 评论(0) 推荐(0) 编辑
摘要: 以下为二叉树的各种遍历的C语言实现程序,包括先序、中序、后序遍历(递归和非递归实现)和层次遍历。 1 #include 2 #include 3 #include 4 #include 5 #include 6 using namespace std; 7 8 typedef struct BiTNode 9 { 10 char data; 11 ... 阅读全文
posted @ 2016-01-04 11:11 Xbert 阅读(237) 评论(0) 推荐(0) 编辑
摘要: 1 #include 2 #include 3 4 using namespace std; 5 6 typedef struct QNode 7 { 8 int data; 9 struct QNode *next; 10 }QNode; //队结点 1... 阅读全文
posted @ 2015-12-30 11:11 Xbert 阅读(281) 评论(0) 推荐(0) 编辑
摘要: 1 #include 2 #include 3 using namespace std; 4 5 #define maxSize 20 6 7 typedef struct 8 { 9 int data[maxSize];10 int front;11 int re... 阅读全文
posted @ 2015-12-30 10:20 Xbert 阅读(155) 评论(0) 推荐(0) 编辑
摘要: 1 #include 2 #include 3 using namespace std; 4 5 typedef struct LNode 6 { 7 int data; 8 struct LNode *next; 9 }LNode;//栈结点定义10 11 void Ini... 阅读全文
posted @ 2015-12-30 09:32 Xbert 阅读(142) 评论(0) 推荐(0) 编辑
摘要: 1 #include 2 #include 3 using namespace std; 4 5 #define maxSize 30 6 7 typedef struct 8 { 9 int data[maxSize];10 int top;11 }SqStack;12 ... 阅读全文
posted @ 2015-12-30 08:53 Xbert 阅读(137) 评论(0) 推荐(0) 编辑
摘要: 1 #include 2 #include 3 using namespace std; 4 5 typedef struct DLNode 6 { 7 int data; 8 struct DLNode *prior; 9 struct DLNode *next;1... 阅读全文
posted @ 2015-12-30 08:52 Xbert 阅读(176) 评论(0) 推荐(0) 编辑
摘要: 1 #include 2 #include 3 using namespace std; 4 //单链表 5 typedef struct LNode 6 { 7 int data; 8 struct LNode *next; 9 }LNode; 10 1... 阅读全文
posted @ 2015-12-29 12:40 Xbert 阅读(147) 评论(0) 推荐(0) 编辑