08 2018 档案

摘要:B1020 月饼(25 分) 月饼是中国人在中秋佳节时吃的一种传统食品,不同地区有许多不同风味的月饼。现给定所有种类月饼的库存量、总售价、以及市场的最大需求量,请你计算可以获得的最大收益是多少。 注意:销售时允许取出一部分库存。样例给出的情形是这样的:假如我们有 3 种月饼,其库存量分别为 18、1 阅读全文
posted @ 2018-08-27 22:17 lingr7 阅读(373) 评论(1) 推荐(0) 编辑
摘要:分组统计 问题 B: 分组统计时间限制: 1 Sec 内存限制: 32 MB 提交: 416 解决: 107 "[提交" ] "[状态" ] "[讨论版" ][命题人:外部导入] 题目描述 先输入一组数,然后输入其分组,按照分组统计出现次数并输出,参见样例。 输入 输入第一行表示样例数m,对于每个样 阅读全文
posted @ 2018-08-26 09:50 lingr7 阅读(1181) 评论(0) 推荐(1) 编辑
摘要:谁是你的潜在朋友 问题 A: 谁是你的潜在朋友时间限制: 1 Sec 内存限制: 32 MB 提交: 950 解决: 310 "[提交" ] "[状态" ] "[讨论版" ][命题人:外部导入] 题目描述 ​ “臭味相投”——这是我们描述朋友时喜欢用的词汇。两个人是朋友通常意味着他们存在着许多共同的 阅读全文
posted @ 2018-08-18 22:16 lingr7 阅读(510) 评论(1) 推荐(0) 编辑
摘要:A1095 Cars on Campus (30)(30 分) Zhejiang University has 6 campuses and a lot of gates. From each gate we can collect the in/out times and the plate nu 阅读全文
posted @ 2018-08-18 18:30 lingr7 阅读(206) 评论(0) 推荐(0) 编辑
摘要:A1083 List Grades (25)(25 分) Given a list of N student records with name, ID and grade. You are supposed to sort the records with respect to the grade 阅读全文
posted @ 2018-08-17 10:43 lingr7 阅读(181) 评论(0) 推荐(0) 编辑
摘要:A1075 PAT Judge (25)(25 分) The ranklist of PAT is generated from the status list, which shows the scores of the submittions. This time you are suppose 阅读全文
posted @ 2018-08-17 10:40 lingr7 阅读(433) 评论(0) 推荐(1) 编辑
摘要:A1012 The Best Rank (25)(25 分) To evaluate the performance of our first year CS majored students, we consider their grades of three courses only: C C 阅读全文
posted @ 2018-08-16 15:27 lingr7 阅读(144) 评论(0) 推荐(0) 编辑
摘要:1009 说反话 (20)(20 分) 给定一句英语,要求你编写程序,将句中所有单词的顺序颠倒输出。 输入格式: 测试输入包含一个测试用例,在一行内给出总长度不超过80的字符串。字符串由若干单词和若干空格组成,其中单词是由英文字母(大小写有区分)组成的字符串,单词之间用1个空格分开,输入保证句子末尾 阅读全文
posted @ 2018-08-13 10:21 lingr7 阅读(513) 评论(1) 推荐(1) 编辑
摘要:A1055 The World's Richest(25 分) Forbes magazine publishes every year its list of billionaires based on the annual ranking of the world's wealthiest pe 阅读全文
posted @ 2018-08-11 19:43 lingr7 阅读(457) 评论(0) 推荐(0) 编辑
摘要:A1025 PAT Ranking (25)(25 分) Programming Ability Test (PAT) is organized by the College of Computer Science and Technology of Zhejiang University. Eac 阅读全文
posted @ 2018-08-11 17:13 lingr7 阅读(253) 评论(0) 推荐(0) 编辑
摘要:A1016 Phone Bills (25)(25 分) A long distance telephone company charges its customers by the following rules: Making a long distance call costs a certa 阅读全文
posted @ 2018-08-11 16:36 lingr7 阅读(149) 评论(0) 推荐(0) 编辑
摘要:1015 德才论 (25)(25 分) 宋代史学家司马光在《资治通鉴》中有一段著名的“德才论”:“是故才德全尽谓之圣人,才德兼亡谓之愚人,德胜才谓之君子,才胜德谓之小人。凡取人之术,苟不得圣人,君子而与之,与其得小人,不若得愚人。” 现给出一批考生的德才分数,请根据司马光的理论给出录取排名。 输入格 阅读全文
posted @ 2018-08-10 11:26 lingr7 阅读(498) 评论(2) 推荐(0) 编辑
摘要:A1035 Password (20)(20 分) To prepare for PAT, the judge sometimes has to generate random passwords for the users. The problem is that there are always 阅读全文
posted @ 2018-08-10 08:21 lingr7 阅读(183) 评论(0) 推荐(0) 编辑
摘要:1048 数字加密(20 分) 本题要求实现一种数字加密方法。首先固定一个加密用正整数 A,对任一正整数 B,将其每 1 位数字与 A 的对应位置上的数字进行以下运算:对奇数位,对应位的数字相加后对 13 取余——这里用 J 代表 10、Q 代表 11、K 代表 12;对偶数位,用 B 的数字减去 阅读全文
posted @ 2018-08-10 07:57 lingr7 阅读(501) 评论(0) 推荐(1) 编辑
摘要:A1061 Dating (20)(20 分) Sherlock Holmes received a note with some strange strings: "Let's date! 3485djDkxh4hhGE 2984akDfkkkkggEdsb s&hgsfdk d&Hyscvnm" 阅读全文
posted @ 2018-08-09 22:58 lingr7 阅读(225) 评论(1) 推荐(0) 编辑
摘要:1024 科学计数法 (20)(20 分) 科学计数法是科学家用来表示很大或很小的数字的一种方便的方法,其满足正则表达式[+ ][1 9]"."[0 9]+E[+ ][0 9]+,即数字的整数部分只有1位,小数部分至少有1位,该数字及其指数部分的正负号即使对正数也必定明确给出。 现以科学计数法的格式 阅读全文
posted @ 2018-08-09 22:57 lingr7 阅读(373) 评论(0) 推荐(0) 编辑
摘要:A1082 Read Number in Chinese (25)(25 分) Given an integer with no more than 9 digits, you are supposed to read it in the traditional Chinese way. Outpu 阅读全文
posted @ 2018-08-09 22:31 lingr7 阅读(171) 评论(0) 推荐(0) 编辑
摘要:1002 写出这个数 (20)(20 分) 读入一个自然数n,计算其各位数字之和,用汉语拼音写出和的每一位数字。 输入格式: 每个测试输入包含1个测试用例,即给出自然数n的值。这里保证n小于10^100^。 输出格式: 在一行内输出n的各位数字之和的每一位,拼音数字间有1 空格,但一行中最后一个拼音 阅读全文
posted @ 2018-08-06 20:49 lingr7 阅读(666) 评论(2) 推荐(0) 编辑
摘要:7 32 7 32 说反话 加强版(20 分) 给定一句英语,要求你编写程序,将句中所有单词的顺序颠倒输出。 输入格式: 测试输入包含一个测试用例,在一行内给出总长度不超过500 000的字符串。字符串由若干单词和若干空格组成,其中单词是由英文字母(大小写有区分)组成的字符串,单词之间用若干个空格分 阅读全文
posted @ 2018-08-06 20:43 lingr7 阅读(6291) 评论(2) 推荐(0) 编辑

点击右上角即可分享
微信分享提示