![](https://img-blog.csdnimg.cn/20201014180756754.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
数据结构
文章平均质量分 65
挨踢实习生
这个作者很懒,什么都没留下…
展开
-
Hanoi
#include int c = 0;void move(char x, int n, char z){ printf("第%d步:将%i号盘从%c移到%c\n",++c, n, x, z);}void hanoi(int n, char x, char y, char z){ if(n == 1) { move(x, n, z); } else { hano原创 2013-04-24 19:18:31 · 616 阅读 · 0 评论 -
Maze
#include #include #define STACK_INIT_SIZE 10#define STACK_INCREMENT 2#define MAXLENGTH 25#define OVERFLOW 0#define FALSE 0#define TRUE 1#define ERROR -1#define OK 1typedef int MazeType[M原创 2013-04-25 12:34:56 · 795 阅读 · 0 评论 -
C语言循环队列
#include #include #define MAX_QSIZE 5#define OVERFLOW 0#define TRUE 1#define FALSE 0#define ERROR -1#define OK 0typedef int QElemType;typedef int Status;struct SqQueue{ QElemType *base;原创 2013-04-20 20:32:43 · 749 阅读 · 0 评论 -
线性表的C语言实现
鉴于老师上课讲的东西太抽象,理论性也太强,估计好多同学都不知老师在说些什么,所以我把线性表的实现用C语言完整的写出来,供大家学习参考,并且也让我温习一下C的知识。希望这样能给大家提供或多或少的帮助。我会尽可能的将注释写全,如果还是看不懂的话,建议先把C语言的书在抱起来看一看。或者是请教一下别的同学。有问题的童鞋请在下边留言,我会及时解答。并且记得关注一下我的微博原创 2013-03-16 09:16:40 · 1336 阅读 · 0 评论 -
C语言顺序栈
#include #include #define STACK_INIT_SIZE 6#define STACK_INCREMENT 5#define OVERFLOW 0#define FALSE 0#define TRUE 1#define ERROR -1#define OK 0typedef int SElemType;typedef int Status;s原创 2013-04-22 11:06:31 · 533 阅读 · 0 评论 -
C++括号匹配程序
v1.0版#include #include #include using namespace std;int main(){ string s; cout << "Please Enter:" << endl; cin >> s; stack cstk; for(int i= 0; i < s.length(); ++i) { char tmp = s原创 2013-03-29 17:05:45 · 932 阅读 · 1 评论 -
C语言线性非循环单链表
#include #include #define OVERFLOW 0#define ERROR -1#define OK 1#define FALSE 0#define TRUE 1typedef int ElemType;typedef int Status;typedef struct LNode{ ElemType data; LNode *next;}L原创 2013-04-20 19:15:53 · 576 阅读 · 0 评论 -
Java实现链式栈
public class LinkedStack { private static class Node { U item; Node next; Node() { item = null; next = null; } Node(U item, Node next) { this.item = item; this.next = next;原创 2013-04-22 09:26:01 · 635 阅读 · 0 评论