- 博客(4)
- 收藏
- 关注
原创 习题9-5 通讯录排序 (20 分)
入n个朋友的信息,包括姓名、生日、电话号码,本题要求编写程序,按照年龄从大到小的顺序依次输出通讯录。题目保证所有人的生日均不相同。 输入格式: 输入第一行给出正整数n(<10)。随后n行,每行按照“姓名 生日 电话号码”的格式给出一位朋友的信息,其中“姓名”是长度不超过10的英文字母组成的字符串,“生日”是yyyymmdd格式的日期,“电话号码”是不超过17位的数字及+、-组成的字符串。 输出格式: 按照年龄从大到小输出朋友的信息,格式同输出。 输入样例: 3 zhang 1985040
2021-06-13 10:49:42
133
原创 7-1 解密英文藏头诗 (15 分)
本题要求编写一个解密英文藏头诗的程序。建议使用动态内存分配方法处理字符串的输入。 输入格式: 输入为一首英文藏头诗,每句一行,小于20行,每行不超过80个字符,以#作为藏头诗的输入结束标志。 输出格式: 取出每句的第一个字符,连接在一起形成一个字符串并输出。 输入样例: I come into a dream Leaves fall down but spring over a lake birds flying village have its nice morning everywhere
2021-06-13 10:45:28
8106
1
原创 自测-5 Shuffling Machine (20 分)
Shuffling is a procedure used to randomize a deck of playing cards. Because standard shuffling techniques are seen as weak, and in order to avoid "inside jobs" where employees collaborate with gamblers by performing inadequate shuffles, many casinos employ
2021-06-13 10:43:26
185
原创 自测-4 Have Fun with Numbers (20 分)
Notice that the number 123456789 is a 9-digit number consisting exactly the numbers from 1 to 9, with no duplication. Double it we will obtain 246913578, which happens to be another 9-digit number consisting exactly the numbers from 1 to 9, only in a diffe
2021-06-13 10:41:42
150
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅