02 2013 档案
摘要:7601. calendarDescription小py是一个熊孩子,他 很想知道某一个日期是星期几,于是他找到了你。请你写一个程序,对于输入的某一个日期,输出1-7中某个数值,表示星期一到星期天中某一天(其中1为星期 一)。由于py是个熊孩子,他可能会说出一个不合法的日期,所以你还需要进行日期合法性判断,非法日期输出-1。Input输入包含多组数据。每行包括三个整数y(2000<=y<=9999), m, d。输入数据以0 0 0结束。Output每组数据输出一行,每行包括一个整数。1表示星期一,7表示星期日,等等,若数据非法,则输出-1。0 0 0不需输出7602. calen
阅读全文
摘要:有首歌的歌词一直很好奇,演唱的瑞典姑娘英文咬字不太清楚,只能听个半懂,但是用Google搜歌词屡搜屡败,只能找到一些人的听写,手头也只有iTunes买来的音源,又不舍得专门买一张CD看BK,最近发现N站的弹幕里有人打了出来,抽出COMMENT之后每行开头都有一部分不需要的时间轴,懒得专门下个软件处理了,干脆自己写试试,运行之后发现效果还不错,好在歌词是英文,处理方便 1 #include<stdio.h> 2 #include<string.h> 3 int main() 4 { 5 char str[200]; 6 int i, len; 7 FILE *ptr =
阅读全文
摘要:DescriptionHengheng is a math nerd. Today he invents a new kind of numbers so called H number. These numbers satisfy that each digit is either the sum or the difference of the adjacent digits. Notice that the first and the last digit are not constrained, except that the first digit is not zero (i.e.
阅读全文
摘要:DescriptionFarmer John has scattered treats for Bessie at special places in the pasture. Since everyone knows that smart cows make tasty milk, FJ has placed the treats at locations that require Bessie to think. He has given her two numbers, P and Q (1 <= P <= 6,000; 1 <= Q <= 6,000), and
阅读全文
摘要:DescriptionBessie wants some toys. She's been saving her allowance for years, and has an incredibly huge stash. However, she is quite frugal and wants to get the best value for her cash. In fact, she has decided only to buy exactly three different toys of the N (3 <= N <= 25,000) offered a
阅读全文
摘要:DescriptionWrite a program that reads in the radius and length of a cylinder and computes volume using the following formulas:area = radius * radius * PIvolume = area * lengthPI = 3.14159 InputOne line contains num1, num2 (both in double) represent the radius and length of a cyliner. OutputThe volum
阅读全文
摘要:Description校歌手大奖赛中每个评委会给每个参赛选手打分,请用类描述每个选手的被评委的评分。选手得分规则为去掉一个最高分和一个最低分,然后计算平均得分,请编程输出某选手的得分。Input输入数据有多组,第一行为数据组数T每组数据第一行两个正整数 n m (3 <= n,m <= 100),表示有 n 个 评 委 , m个选手。接下来 n 行,每行 m 个正整数。每行表示一个评委给 m 个选手的分数,分数为[0,100]的整数。Output请将结果输出对于每组输入数据输出 m 行,每行表示一个选手的得分,结果保留 2 位小数。水题,二维数组存储,一维数组记录最高最低分,最后统
阅读全文
摘要:DescriptionZSUQ Messenger is similar with Tencent QQ. Each user will make a nickname for itself. Different users can have identical nickname. Some common ones, such as “Tom”, “Marry”, “Kate”, are frequently used. In a recent survey, the ZSUQ Company was astonished to find that there are no more than
阅读全文

浙公网安备 33010602011771号