-
thank you
舞会上男女各排成一队进入舞厅,跳舞时依次从男士队伍和女士队伍的队头各出一个人相互结成舞伴。如果两队的人数不等,则队伍较长中未配对的人员将等待下一轮的舞曲。
要求用程序完成该配对过程的模拟,从键盘输入所有人员的名单,输入格式为“姓名 性别”,并且男女无序,输出所有配对的男女舞伴,如果某队伍中还有人员未配对完,则另外输出所有尚未配对人员名单。
选作内容:
1. 实现下一轮次的继续配对,此时,所有尚未配对的人员应优先予以配对;
2. 将姓名与性别数据存放在文本文件中,直接从文本中读入数据。
实现说明:
1. 总是排在队头的男女相互结成舞伴,具有队列的先进先出特征,因此采用队列来完成;
2. 采用两个队列分别存放男士和女士的姓名,所有输入的人员按照性别依次分解到各自的队列中,然后顺次取出各自的队头元素来配对并输出;
3. 队列类的数据类型可以是字符数组,也可以先实现模板类,再用字符数组来实例化实现。-thank you
- 2022-03-01 16:14:45下载
- 积分:1
-
自动ping出来,然后挂断。非常好的一个东西。没密码
自动ping出来,然后挂断。非常好的一个东西。没密码-Automatically ping out, and then hang up. A very good thing. No password
- 2022-05-13 23:07:22下载
- 积分:1
-
Based on the AMD Au1200 (MIPS32 processor) of the AC97 driver source code, have...
基于AMD Au1200(MIPS32处理器)的AC97驱动源码,经测试能达到很好的立体声效果-Based on the AMD Au1200 (MIPS32 processor) of the AC97 driver source code, have been tested to achieve good stereo effect
- 2023-08-24 02:35:03下载
- 积分:1
-
nes模拟器,viusal basic写的,想研究nes模拟器的看看吧
nes模拟器,viusal basic写的,想研究nes模拟器的看看吧-nes simulator, viusal basic writing and wants to study nes simulators let"s see it
- 2022-07-05 03:08:46下载
- 积分:1
-
VC with the phone book to prepare procedures for the console way, scores of grou...
用VC编写的电话本程序,为控制台程,分数组和链表两个版本-VC with the phone book to prepare procedures for the console way, scores of groups and list two versions
- 2022-02-11 22:17:57下载
- 积分:1
-
VC platform in a clock dial the development of simple and intuitive for beginner...
在VC平台下实现了表盘时钟的开发,简单直观,适合初学者参考。-VC platform in a clock dial the development of simple and intuitive for beginners reference.
- 2022-08-06 18:48:29下载
- 积分:1
-
一个课程设计,数据结构的, 1)设计题目 2)设计目的 3)设计内容 4)程序流程图 5)源程序 6)软件测试报告(包括所用到的数据及结果)...
一个课程设计,数据结构的, 1)设计题目 2)设计目的 3)设计内容 4)程序流程图 5)源程序 6)软件测试报告(包括所用到的数据及结果)-a curriculum design, data structure, 1) a design 2), designed to 3) design element 4) Flow chart 5) source 6) software test reports (including use of the data and results)
- 2022-01-31 23:28:16下载
- 积分:1
-
win32api程序,读取256级灰度图并显示其文件头信息,彻底了解位图文件头结构...
win32api程序,读取256级灰度图并显示其文件头信息,彻底了解位图文件头结构-win32api program, which can read 256 grid map and show its head message,understand the title stucture of bitmap
- 2022-02-21 05:38:28下载
- 积分:1
-
基本参考Python的第二版比Python
python精要参考第二版,比Python简易深入一些,相比dive into python 更直接一些-Essential reference to the second edition of python than Python-depth summary of some, compared to dive into python some more direct
- 2022-01-25 14:43:15下载
- 积分:1
-
客户信息管理系统DEMO及源程序,使用xpmenut等控件
客户信息管理系统DEMO及源程序,使用xpmenut等控件-DEMO customer information management system and source code, the use of such controls xpmenut
- 2022-07-02 02:09:23下载
- 积分:1