摘要: 两个大整数的除法 Problem Description 计算两个大整数的商 Input 共2行,每行一个大整数 Output 共1行,表示两个大整数的商(整数部分) Sample Input 100 3 Sample Output 33 1 #include<stdio.h> 2 #include 阅读全文
posted @ 2019-07-19 15:49 龚政 阅读(650) 评论(0) 推荐(0) 编辑
摘要: N的阶乘 Problem Description 计算一个正整数的阶乘,数据范围[1,1000] Input 每行一个整数N Output 每行一个整数,表示N的阶乘 Sample Input 2 5 Sample Output 2 120 1 #include<stdio.h> 2 int mai 阅读全文
posted @ 2019-07-19 15:49 龚政 阅读(483) 评论(0) 推荐(0) 编辑
摘要: Problem Description 计算两个大整数的乘积 Input 共2行,每行一个大整数 Output 共1行,表示两个大整数的乘积 Sample Input 112233445566778899 100000000000000000 Sample Output 11223344556677 阅读全文
posted @ 2019-07-19 15:48 龚政 阅读(382) 评论(0) 推荐(0) 编辑
摘要: 两个大整数的加法 Problem Description 计算两个大整数的加法 Input 共2行,每行一个大整数 Output 一行,两个大整数的和. Sample Input 1122334455 3333333333 Sample Output 4455667788 1 #include<st 阅读全文
posted @ 2019-07-19 15:47 龚政 阅读(455) 评论(0) 推荐(0) 编辑
摘要: Big Number Problem Description As we know, Big Number is always troublesome. But it's really important in our ACM. And today, your task is to write a 阅读全文
posted @ 2019-07-19 15:46 龚政 阅读(238) 评论(0) 推荐(0) 编辑
摘要: Who will be punished Problem Description This time,suddenly,teacher Li wants to find out who have missed interesting DP lesson to have fun.The student 阅读全文
posted @ 2019-07-19 15:44 龚政 阅读(222) 评论(0) 推荐(0) 编辑
摘要: Problem Description In the new year party, everybody will get a "special present".Now it's your turn to get your special present, a lot of presents no 阅读全文
posted @ 2019-07-19 15:41 龚政 阅读(212) 评论(0) 推荐(0) 编辑
摘要: Being a Good Boy in Spring Festival Problem Description 一年在外 父母时刻牵挂春节回家 你能做几天好孩子吗寒假里尝试做做下面的事情吧陪妈妈逛一次菜场悄悄给爸爸买个小礼物主动地 强烈地 要求洗一次碗某一天早起 给爸妈用心地做回早餐如果愿意 你还可 阅读全文
posted @ 2019-07-19 15:39 龚政 阅读(198) 评论(0) 推荐(0) 编辑
摘要: 二进制串的逆转 Problem Description 将一个32位整数的二进制表示串的值逆转。如1的二进制表示为:0000 0000 0000 0001,逆转之后为1000 0000 0000 0000 Input 每行一个32位的整数 Output 每行为位逆转后的整数 Sample Input 阅读全文
posted @ 2019-07-19 14:43 龚政 阅读(589) 评论(0) 推荐(0) 编辑
摘要: 高低位交换 Font: Times New Roman | Verdana | Georgia Font Size: ← → Problem Description 给出一个小于2^32的正整数。这个数可以用一个32位的二进制数表示(不足32位用0补足)。我们称这个二进制数的前16位为“高位”,后1 阅读全文
posted @ 2019-07-19 13:53 龚政 阅读(2351) 评论(0) 推荐(0) 编辑
摘要: 与众不同的数 Problem Description Hnfnu希望从一个巨大的数字群(大概有100,000,000个数据)中找一个数字,这个数字群有个特点:除了Hnfnu要找的数字之外,其余的数字都出现了偶数次。 Input n个整数 Output 输出那个与众不同的数 Sample Input 阅读全文
posted @ 2019-07-19 13:51 龚政 阅读(245) 评论(0) 推荐(0) 编辑
摘要: 平均值 Problem Description 现有二个正整数a和b,设a、b均不超过64位无符号数的取值范围,输出其平均值的整数部分(舍去小数)。 Input 2个整数 Output 输出2个整数的平均数 Sample Input 5 6 Sample Output 5 分析: 这主要是可能出现溢 阅读全文
posted @ 2019-07-19 13:50 龚政 阅读(181) 评论(0) 推荐(0) 编辑
摘要: A+B Problem Description A+B Input 11 Output 2 Sample Input 1 2 Sample Output 3 解释: 双手打字,以示清白。 1 #include<bits/stdc++.h> 2 3 using namespace std; 4 5 6 阅读全文
posted @ 2019-07-19 11:59 龚政 阅读(424) 评论(0) 推荐(0) 编辑
摘要: The kth great number Problem Description Xiao Ming and Xiao Bao are playing a simple Numbers game. In a round Xiao Ming can choose to write down a num 阅读全文
posted @ 2019-07-19 11:58 龚政 阅读(348) 评论(0) 推荐(0) 编辑
摘要: The Frog's Games Problem Description The annual Games in frogs' kingdom started again. The most famous game is the Ironfrog Triathlon. One test in the 阅读全文
posted @ 2019-07-19 11:48 龚政 阅读(286) 评论(0) 推荐(0) 编辑
摘要: The order of a Tree Problem Description As we know,the shape of a binary search tree is greatly related to the order of keys we insert. To be precisel 阅读全文
posted @ 2019-07-19 11:29 龚政 阅读(222) 评论(0) 推荐(0) 编辑
摘要: 圆圈 Problem Description 在一个二维平面上,每个整数点坐标处都放了一块钱,如(1,2)、(1,1)等。现在以(0,0)为圆心画一个半径为r的圆,问圆内(包括圆圈边)上一共有多少钱。 Input 输入有多组测试数据,每组测试数据一行输入一个整数r(r<=25000)表示圆的半径,输 阅读全文
posted @ 2019-07-19 10:49 龚政 阅读(310) 评论(0) 推荐(0) 编辑
摘要: 滑雪 Problem Description Michael喜欢滑雪,这并不奇怪, 因为滑雪的确很刺激。可是为了获得速度,滑的区域必须向下倾斜,而且当你滑到坡底,你不得不再次走上坡或者等待升降机来载你。Michael想知道在一个区域中最长的滑坡。区域由一个二维数组给出。数组的每个数字代表点的高度。下 阅读全文
posted @ 2019-07-19 10:43 龚政 阅读(183) 评论(0) 推荐(0) 编辑
摘要: Larkin’s NOI Problem Description Larkin has been to Yantai to take part in NOI 2010!众所周知(do you know?),NOI比赛中有两类题目:传统试题(就是你们现在正在做的这类)和提交答案型试题(就是给你输入文件 阅读全文
posted @ 2019-07-19 09:41 龚政 阅读(121) 评论(0) 推荐(0) 编辑
摘要: 整数的进位制 Problem Description 给你一个10进制数,让你处理以下操作:1.T a。意义为:将当前的数转换成a进制数。2.A a。意义为:将当前的数加上十进制下的a。3.M a。意义为:将当前的数减去十进制下的a。4.C。意义为:将当前的数的最后一位去掉。如果当前的数为0,那么该 阅读全文
posted @ 2019-07-19 09:28 龚政 阅读(381) 评论(0) 推荐(0) 编辑