
队列
小雪乃
这个作者很懒,什么都没留下…
展开
-
PAT 甲级 1014. Waiting in Line (30)
Suppose a bank has N windows open for service. There is a yellow line in front of the windows which devides the waiting area into two parts. The rules for the customers to wait in line are:The s原创 2017-09-20 16:29:05 · 257 阅读 · 0 评论 -
PAT 甲级 1056. Mice and Rice (25)
Mice and Rice is the name of a programming contest in which each programmer must write a piece of code to control the movements of a mouse in a given map. The goal of each mouse is to eat as much rice原创 2017-10-01 11:24:21 · 202 阅读 · 0 评论 -
蓝桥杯 算法提高 队列操作
问题描述 队列操作题。根据输入的操作命令,操作队列(1)入队、(2)出队并输出、(3)计算队中元素个数并输出。 输入格式 第一行一个数字N。 下面N行,每行第一个数字为操作命令(1)入队、(2)出队并输出、(3)计算队中元素个数并输出。 输出格式 若干行每行显示一个2或3命令的输出结果。注意:2.出队命令可能会出现空队出队(下溢),请输出“no”,并退出。 样例输入原创 2017-12-09 17:31:00 · 158 阅读 · 0 评论