📄 main.c
字号:
#include <stdio.h>
#include <stdlib.h>
#include "operate_Lqueue.h"
main()
{
int scan_switch,scan_max;
Queue_p *Strat;
L_queue *s_queue;
s_queue=(L_queue *)malloc(sizeof(L_queue));
s_queue->next=NULL;
Strat=(Queue_p *)malloc(sizeof(Queue_p));
while(1)
{
printf("1.建立front/rear指针,空表\n");
printf("2.入队列\n");
printf("3.显示队列\n");
printf("4.出队列\n");
printf("选择操作码:");
scanf("%d",&scan_switch);
switch(scan_switch)
{
case 1:
Emplty_Queue(Strat,s_queue);break;
case 2:
{
printf("输入元素个数:");
scanf("%d",&scan_max);
Insert_Queue(Strat,scan_max);
}break;
case 3:Out_Queue(Strat);break;
case 4:Push_Queue(Strat);break;
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -