📄 shuju.h
字号:
//函数结果状态代码
#define TRUE 1
#define FALSE 0
#define OK 1
#define ERROR 0
#define INFEASIBLE -1
#define OVERFLOW -2
#define NULL 0
typedef int Status;//函数的类型,其值是函数结果状态代码
typedef int QElemType;
#include"stdio.h"
#include "stdlib.h"
//#define STACK_INIT_SIZE 100//存储空间的初始分配量
//#define STACKINCREMENT 10//存储空间的分配增量
typedef struct QNode{
QElemType front;//栈顶指针
QElemType rear; //在栈构造之前和销毁之后,base的值未NULL
}LinkQueue;
//基本操作的函数原型说明
Status InitQueue(LinkQueue &Q);
Status QueueEmpty(LinkQueue Q);
int QueueLength(LinkQueue Q);
Status GetHead(LinkQueue Q,QElemType &e);
Status EnQueue(LinkQueue &Q,QElemType e);
Status DeQueue(LinkQueue &Q,QElemType &e);
Status QueueTraverse(LinkQueue &Q,Status(*visit()));//
Status DestoryQueue(LinkQueue &Q);
Status ClearQueue(LinkQueue &Q);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -