摘要: Description Description 求组合数C(n,m) 求组合数C(n,m) Input Input T(0 < T < 2000) 每组样例两个数n, m(0 < n, m< 60) T(0 < T < 2000) 每组样例两个数n, m(0 < n, m< 60) 每组样例两个数n 阅读全文
posted @ 2019-06-08 21:22 明霞 阅读(213) 评论(0) 推荐(0) 编辑
摘要: Description Description (the picture has no relation with this problem..I just want to add a picture. emmm..) Super scholar robs the all homework of o 阅读全文
posted @ 2019-06-08 20:58 明霞 阅读(193) 评论(0) 推荐(0) 编辑
摘要: Description Description 实现public static boolean isSorted(int[] table) 判断整数数组元素是否已经按升序排序。 实现public static boolean isSorted(int[] table) 判断整数数组元素是否已经按升序 阅读全文
posted @ 2019-06-08 18:55 明霞 阅读(874) 评论(0) 推荐(0) 编辑
摘要: Description Description 磊磊想在学校中请一些同学一起做一项问卷调查,为了实验的客观性,他先用计算机生成了N个1到1000之间的随机整数(N≤100),对于其中重复的数字,只保留一个,把其余相同的数去掉,不同的数对应着不同的学生的学号。然后再把这些数从小到大排序,按照排好的顺序 阅读全文
posted @ 2019-06-08 18:49 明霞 阅读(202) 评论(0) 推荐(0) 编辑
摘要: Description Description 一元 n 次多项式可用如下的表达式表示: f(x)=an*x^n+an-1*x^n-1+...+a1*x+a0 (an≠0) 其中,a_i·x^i 称为i次项,a_i称为i 次项的系数。给出一个一元多项式各项的次数和系数,请按照如下规定的格式要求输出该 阅读全文
posted @ 2019-06-08 17:08 明霞 阅读(233) 评论(0) 推荐(0) 编辑
摘要: Description Description 一个整数总可以拆分为2的幂的和,例如: 7=1+2+4 7=1+2+2+2 7=1+1+1+4 7=1+1+1+2+2 7=1+1+1+1+1+2 7=1+1+1+1+1+1+1 总共有六种不同的拆分方式。 再比如:4可以拆分成:4 = 4,4 = 1 阅读全文
posted @ 2019-06-08 16:36 明霞 阅读(190) 评论(0) 推荐(0) 编辑
摘要: Description Description 小明对生日十分看重,因为他可以得到祝福,可以和朋友亲人一起分享快乐,可以为自己的人生做一次总结,并且...能够收到好多礼物! 不过小明是个神秘的人,不会轻易告诉你他的生日,现在他想到一个办法,让你去猜他的生日是哪一天。小明会告诉你如下三个信息:1. 出 阅读全文
posted @ 2019-06-08 15:58 明霞 阅读(461) 评论(0) 推荐(0) 编辑
摘要: Description Description Starting from point (0,0) on a plane, we have written all non-negative integers 0, 1, 2,... as shown in the figure. For exampl 阅读全文
posted @ 2019-06-08 14:49 明霞 阅读(237) 评论(0) 推荐(0) 编辑
摘要: Description Description 再次出个排序题,题目是这样的,输入一行数字,如果我们把这行数字中的‘5’都看成空格,那么就得到一行用空格分割的若干非负整数(可能有些整数以‘0’开头,这些头部的‘0’应该被忽略掉,除非这个整数就是由若干个‘0’组成的,这时这个整数就是0)。你的任务是: 阅读全文
posted @ 2019-06-08 11:57 明霞 阅读(173) 评论(0) 推荐(0) 编辑