简单数学题
文章平均质量分 64
落叶晚秋
努力,变得更强!!!
展开
-
2015 ACM/ICPC Asia Regional Shanghai Online-1010-A Sweet Journey
Master Di plans to take his girlfriend for a travel by bike. Their journey, which can be seen as a line segment of length L, is a road of swamps and flats. In the swamp, it takes A point strengths p原创 2015-09-26 13:05:24 · 386 阅读 · 0 评论 -
杭电oj-1229-还是A+B
Problem Description读入两个小于10000的正整数A和B,计算A+B。需要注意的是:如果A和B的末尾K(不超过8)位数字相同,请直接输出-1。Input测试输入包含若干测试用例,每个测试用例占一行,格式为"A B K",相邻两数字有一个空格间隔。当A和B同时为0时输入结束,相应的结果不要输出。Output对每个测试用例输出1行,即A+B的值或者原创 2016-03-29 22:34:27 · 430 阅读 · 0 评论 -
杭电oj-1205-吃糖果
Problem DescriptionHOHO,终于从Speakless手上赢走了所有的糖果,是Gardon吃糖果时有个特殊的癖好,就是不喜欢将一样的糖果放在一起吃,喜欢先吃一种,下一次吃另一种,这样;可是Gardon不知道是否存在一种吃糖果的顺序使得他能把所有糖果都吃完?请你写个程序帮忙计算一下。Input第一行有一个整数T,接下来T组数据,每组数据占2行,第一行是一个整数N原创 2016-03-29 21:55:58 · 898 阅读 · 0 评论 -
杭电oj-1303-Doubles
Problem DescriptionAs part of an arithmetic competency program, your students will be given randomly generated lists of from 2 to 15 unique positive integers and asked to determine how many items in原创 2015-11-30 23:12:42 · 390 阅读 · 0 评论 -
杭电oj-1170-Balloon Comes!
Problem DescriptionThe contest starts now! How excited it is to see balloons floating around. You, one of the best programmers in HDU, can get a very beautiful balloon if only you have solved the ve原创 2015-11-30 19:28:21 · 379 阅读 · 0 评论 -
杭电oj-1106-排序
Problem Description输入一行数字,如果我们把这行数字中的‘5’都看成空格,那么就得到一行用空格分割的若干非负整数(可能有些整数以‘0’开头,这些头部的‘0’应该被忽略掉,除非这个整数就是由若干个‘0’组成的,这时这个整数就是0)。你的任务是:对这些分割得到的整数,依从小到大的顺序排序输出。Input输入包含多组测试用例,每组输入数据只有一行数字(数字之原创 2015-11-02 21:48:38 · 541 阅读 · 0 评论 -
杭电oj-1076-An Easy Task
Problem DescriptionIgnatius was born in a leap year, so he want to know when he could hold his birthday party. Can you tell him?Given a positive integers Y which indicate the start year, and a p原创 2015-11-02 19:29:51 · 509 阅读 · 0 评论 -
杭电oj—1219—AC Me
Problem DescriptionIgnatius is doing his homework now. The teacher gives him some articles and asks him to tell how many times each letter appears.It's really easy, isn't it? So come on and AC ME.原创 2015-10-27 21:31:10 · 510 阅读 · 0 评论 -
杭电oj-1215-七夕节
Problem Description七夕节那天,月老来到数字王国,他在城门上贴了一张告示,并且和数字王国的人们说:"你们想知道你们的另一半是谁吗?那就按照告示上的方法去找吧!"人们纷纷来到告示前,都想知道谁才是自己的另一半.告示如下:数字N的因子就是所有比N小又能被N整除的所有正整数,他们的和就代表另一半的编号,如12的因子有1,2,3,4,6.你想知道你的另一半吗?原创 2015-10-22 23:21:19 · 1041 阅读 · 1 评论 -
杭电oj-1040-As Easy As A+B
Problem DescriptionThese days, I am thinking about a question, how can I get a problem as easy as A+B? It is fairly difficulty to do such a thing. Of course, I got it after many waking nights.Give原创 2015-10-21 21:54:39 · 457 阅读 · 0 评论 -
弱校联萌十一大决战之如日中天-C. Cinderella
Cinderella is given a task by her Stepmother before she is allowed to go to the Ball. There are N (1 ≤ N ≤ 1000) bottles with water in the kitchen. Each bottle contains Li (0 ≤ Li ≤ 10^6) ounces of wa原创 2015-10-04 12:45:20 · 368 阅读 · 0 评论 -
杭电oj-1228-A+B
Problem Description读入两个小于100的正整数A和B,计算A+B.需要注意的是:A和B的每一位数字由对应的英文单词给出.Input测试输入包含若干测试用例,每个测试用例占一行,格式为"A + B =",相邻两字符串有一个空格间隔.当A和B同时为0时输入结束,相应的结果不要输出. Output对每个测试用例输出1行,即A+B的值.Sample原创 2015-11-03 21:02:00 · 544 阅读 · 0 评论 -
杭电oj-1406-完数
Problem Description完数的定义:如果一个大于1的正整数的所有因子之和等于它的本身,则称这个数是完数,比如6,28都是完数:6=1+2+3;28=1+2+4+7+14。本题的任务是判断两个正整数之间完数的个数。Input输入数据包含多行,第一行是一个正整数n,表示测试实例的个数,然后就是n个测试实例,每个实例占一行,由两个正整数num1和num2组成原创 2016-03-30 16:41:53 · 525 阅读 · 0 评论