-
c++链式队列的实现
c++链式队列的实现头文件如下:
typedef int Item;
typedef struct node * PNode;
typedef struct node
{
Item data;
PNode next;
}Node;
typedef struct
{
PNode front;
PNode rear;
int size;
}Queue;
/*构造一个空队列*/
Queue *InitQueue();
/*销毁一个队列*/
void DestroyQueue(Queue *pqueue);
/*清空一个队列*/
void ClearQueue(Queue *pqueue);
/*判断队列是否为空*/
int IsEmpty(Queue *pqueue);
/*返回队列大小*/
int GetSize(Queue *pqueue);
/*返回队头元素*/
PNode GetFront(Queue *pqueue,Item *pitem);
/*返回队尾元素*/
PNode GetRear(Queue *pqueue,Item *pitem);
/*将新元素入队*/
PNode EnQueue(Queue *pqueue,Item item);
/*队头元素出队*/
PNode DeQueue(Queue *pqueue,Item *pitem);
/*遍历队列并对各数据项调用visit函数*/
void QueueTraverse(Queue *pqueue,void (*visit)());
- 2023-09-04 20:50:03下载
- 积分:1
-
思想很简单,就是一个循环链表
但要说明的是:我之所以用clist(1)来初始化,主要是我刚开始编的时候没打算解决约瑟夫环,只是想编一个带表头的循环链表...
思想很简单,就是一个循环链表
但要说明的是:我之所以用clist(1)来初始化,主要是我刚开始编的时候没打算解决约瑟夫环,只是想编一个带表头的循环链表,然后我用从这个程序改过来的,所以代码可以进一步优化。-Thinking is very simple, that is, a cycle list but would like to note is: I use clist (1) to initialize, mainly because I had just started when Joseph did not intend to resolve the ring, just want to provision a table with the head circulation list, and then I used to come from this process, so the code can be further optimized.
- 2022-09-15 15:25:03下载
- 积分:1
-
VB为前台,SQL_SERVER为后台的关于宾馆的数据库编程
VB为前台,SQL_SERVER为后台的关于宾馆的数据库编程-prospects for VB, SQL_SERVER background on the hotel Database Programming
- 2022-03-14 22:29:19下载
- 积分:1
-
实现二叉树的一部分功能,有需要的可以下载来
实现二叉树的一部分功能,有需要的可以下载来-Part of the realization of binary functions, can be downloaded in need to look at
- 2022-07-25 03:44:11下载
- 积分:1
-
利用MATLAB程序贪心算法求解背包问题
背包问题运用贪婪算法的matlab 程序实现-Use of greedy algorithm knapsack problem of matlab program
- 2022-01-27 12:11:55下载
- 积分:1
-
本设计完成了要求的所有功能,.能存储足够大的大整数并进行相应的加减法运算。用户界面友好,有用户使用说明,每一步操作都有说明与提示。程序运行通过,有详细的解释说明...
本设计完成了要求的所有功能,.能存储足够大的大整数并进行相应的加减法运算。用户界面友好,有用户使用说明,每一步操作都有说明与提示。程序运行通过,有详细的解释说明。-the design completed all the required functions. Can store large enough large integer and the corresponding addition and subtraction operations. User friendly interface, users note, every step of the operation have notes and hints. Running through a detailed explanation.
- 2022-04-21 03:39:00下载
- 积分:1
-
FP树算法源代码 FP树算法源代码
FP树算法源代码 FP树算法源代码-tree FP algorithm source code tree FP algorithm source code tree algorithm source code
- 2022-09-29 00:20:03下载
- 积分:1
-
北大ACM1003(Hangover)
北大ACM1003(Hangover)-North ACM1003 (Hangover)
- 2022-02-03 12:26:03下载
- 积分:1
-
May realize a web service database query, update, delete a feature, simple and d...
实现了 web service得数据库查询,更新,删除得功能,简便耐用。-May realize a web service database query, update, delete a feature, simple and durable.
- 2022-06-21 06:54:53下载
- 积分:1
-
一些常用的几何算法的C++实现,包括两点确定一条直线,两点间距离,点直线距离, 海伦公式求三角形面积,判断直线相交等...
一些常用的几何算法的C++实现,包括两点确定一条直线,两点间距离,点直线距离, 海伦公式求三角形面积,判断直线相交等-some common geometric algorithm C achieved, including two identified a straight line, the distance between two points, point straight distance Helen formula for triangle area, as judged straight intersection
- 2022-06-27 00:57:26下载
- 积分:1