![](https://csdnimg.cn/release/download_crawler_static/86079752/bg4.jpg)
修改航班信息:
当航班信息改变可以修改航班数据文件
要求:
根据以上功能说明,设计航班信息,订票信息的存储结构,设计程序完成功能;
6、 文章编辑
功能要求:输入一页文字,程序可以统计出文字、数字、空格的个数。
(1)静态存储一页文章,每行最多不超过80个字符,共N行;要求
� 分别统计出其中英文字母数和空格数与整篇文章总字数;
� 统计某一字符串在文章中出现的次数,并输出该次数;
� 删除某一子串,并将后面的字符前移。
(2)存储结构使用线性表,分别用几个子函数实现相应的功能;
(3)输入数据的形式和围:可以输入大写、小写的英文字母、任何数字与标点符号。
(4)输出形式:
1) 分行输出用户输入的各行字符;
2) 分4行输出"全部字母数"、"数字个数"、"空格个数"、"文章总字数"
输出删除某一字符串后的文章。
7、设计题目 joseph 环
任务:编号是 1,2,……,n 的 n 个人按照顺时针方向围坐一圈,每个人只有一个密码
(正整数)。一开始任选一个正整数作为报数上限值 m,从第一个仍开始顺时针方向自 1 开
始顺序报数,报到 m 时停止报数。报 m 的人出列,将他的密码作为新的 m 值,从他在顺时
针方向的下一个人开始重新从 1 报数,如此下去,直到所有人全部出列为止。设计一个程
序来求出出列顺序。
要求:利用单向循环链表存储结构模拟此过程,按照出列的顺序输出各个人的编号。
8、Channel Allocation
When a radio station is broadcasting over a very large area, repeaters are used to
retransmit the signal so that every receiver has a strong signal. However, the channels
used by each repeater must be carefully chosen so that nearby repeaters do not interfere
with one another. This condition is satisfied if adjacent repeaters use different channels.
Since the radio frequency spectrum is a precious resource, the number of channels
required by a given network of repeaters should be minimised. You have to write a
program that reads in a description of a repeater network and determines the minimum
number of channels required.
INPUT
The input consists of a number of maps of repeater networks. Each map begins
with a line containing the number of repeaters. This is between 1 and 26, and the
repeaters are referred to by consecutive upper-case letters of the alphabet starting with A.
For example, ten repeaters would have the names A,B,C,...,I and J. A network with zero
repeaters indicates the end of input. Following the number of repeaters is a list of
adjacency relationships. Each line has the form: A:BCDH which indicates that the
repeaters B, C, D and H are adjacent to the repeater A. The first line describes those