上一页 1 ··· 29 30 31 32 33 34 35 36 37 ··· 41 下一页
摘要: Problem Description完数的定义:如果一个大于1的正整数的所有因子之和等于它的本身,则称这个数是完数,比如6,28都是完数:6=1+2+3;28=1+2+4+7+14。本题的任务是判断两个正整数之间完数的个数。Input输入数据包含多行,第一行是一个正整数n,表示测试实例的个数,然后... 阅读全文
posted @ 2014-11-09 12:29 zqxLonely 阅读(1488) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionSmall W gets two files. There are n integers in each file. Small W wants to know whether these two files are same. So he invites yo... 阅读全文
posted @ 2014-11-06 21:36 zqxLonely 阅读(291) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionFor this problem, you will write a program that prints theNthlargest value in a fixed sized array of integers. To make things simpl... 阅读全文
posted @ 2014-11-06 19:53 zqxLonely 阅读(326) 评论(0) 推荐(0) 编辑
摘要: Problem Description给定一系列2维平面点的坐标(x, y),其中x和y均为整数,要求用一个最小的长方形框将所有点框在内。长方形框的边分别平行于x和y坐标轴,点落在边上也算是被框在内。Input测试输入包含若干测试用例,每个测试用例由一系列坐标组成,每对坐标占一行,其中|x|和|y|... 阅读全文
posted @ 2014-11-01 12:53 zqxLonely 阅读(632) 评论(0) 推荐(0) 编辑
摘要: Problem Description统计一个给定字符串中指定的字符出现的次数Input测试输入包含若干测试用例,每个测试用例包含2行,第1行为一个长度不超过5的字符串,第2行为一个长度不超过80的字符串。注意这里的字符串包含空格,即空格也可能是要求被统计的字符之一。当读到'#'时输入结束,相应的结... 阅读全文
posted @ 2014-11-01 11:22 zqxLonely 阅读(481) 评论(0) 推荐(0) 编辑
摘要: Problem Description话说辽军与MCA相峙多年,终于在一个秋日的早晨爆发了一次大规模的冲突.情况是这样子的,当天上午,由耶律-Pacision领军的辽军忽然带领数万人马浩浩荡荡向MCA山杀来,而这时候驻扎在MCA防守前线的是久经沙场的老将纪哥.纪哥得知这个消息,立刻召集手下精英,前往... 阅读全文
posted @ 2014-11-01 00:17 zqxLonely 阅读(480) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionFatMouse prepared M pounds of cat food, ready to trade with the cats guarding the warehouse containing his favorite food, JavaBean.... 阅读全文
posted @ 2014-10-30 23:29 zqxLonely 阅读(299) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionI have a very simple problem for you. Given two integers A and B, your job is to calculate the Sum of A + B.InputThe first line of ... 阅读全文
posted @ 2014-10-30 21:15 zqxLonely 阅读(261) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionA number sequence is defined as follows:f(1) = 1, f(2) = 1, f(n) = (A * f(n - 1) + B * f(n - 2)) mod 7.Given A, B, and n, you are t... 阅读全文
posted @ 2014-10-30 14:02 zqxLonely 阅读(246) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionGiven a sequence a[1],a[2],a[3]......a[n], your job is to calculate the max sum of a sub-sequence. For example, given (6,-1,5,4,-7)... 阅读全文
posted @ 2014-10-30 12:51 zqxLonely 阅读(310) 评论(0) 推荐(0) 编辑
上一页 1 ··· 29 30 31 32 33 34 35 36 37 ··· 41 下一页