上一页 1 ··· 7 8 9 10 11 12 13 14 15 ··· 20 下一页
摘要: 题目描述 金明今天很开心,家里购置的新房就要领钥匙了,新房里有一间金明自己专用的很宽敞的房间。更让他高兴的是,妈妈昨天对他说:“你的房间需要购买哪些物品,怎么布置,你说了算,只要不超过NN元钱就行”。今天一早,金明就开始做预算了,他把想买的物品分为两类:主件与附件,附件是从属于某个主件的,下表就是一 阅读全文
posted @ 2019-04-16 00:08 WAKBGAN 阅读(183) 评论(0) 推荐(0) 编辑
摘要: Gappu has a very busy weekend ahead of him. Because, next weekend is Halloween, and he is planning to attend as many parties as he can. Since it's Hal 阅读全文
posted @ 2019-04-14 17:07 WAKBGAN 阅读(161) 评论(0) 推荐(0) 编辑
摘要: Description The multiplication puzzle is played with a row of cards, each containing a single positive integer. During the move player takes one card 阅读全文
posted @ 2019-04-14 14:25 WAKBGAN 阅读(135) 评论(0) 推荐(0) 编辑
摘要: Description We give the following inductive definition of a “regular brackets” sequence: the empty sequence is a regular brackets sequence, if s is a 阅读全文
posted @ 2019-04-14 13:25 WAKBGAN 阅读(134) 评论(0) 推荐(0) 编辑
摘要: 题目描述 在一个圆形操场的四周摆放N堆石子,现要将石子有次序地合并成一堆.规定每次只能选相邻的2堆合并成新的一堆,并将新的一堆的石子数,记为该次合并的得分。 试设计出1个算法,计算出将N堆石子合并成1堆的最小得分和最大得分. 输入输出格式 输入格式: 数据的第1行试正整数N,1≤N≤100,表示有N 阅读全文
posted @ 2019-04-13 20:34 WAKBGAN 阅读(311) 评论(0) 推荐(1) 编辑
摘要: B. The least round way time limit per test 2 seconds memory limit per test 64 megabytes input standard input output standard output B. The least round 阅读全文
posted @ 2019-04-10 21:49 WAKBGAN 阅读(206) 评论(0) 推荐(0) 编辑
摘要: Description A Bank plans to install a machine for cash withdrawal. The machine is able to deliver appropriate @ bills for a requested cash amount. The 阅读全文
posted @ 2019-04-10 18:46 WAKBGAN 阅读(174) 评论(0) 推荐(0) 编辑
摘要: 当求解公式:(a/b)%m 时,因b可能会过大,会出现爆精度的情况,所以需变除法为乘法: 设c是b的逆元,则有b*c≡1(mod m); 则(a/b)%m = (a/b)*1%m = (a/b)*b*c%m = a*c(mod m); 即a/b的模等于a*b的逆元的模; 逆元就是这样应用的; 所以逆 阅读全文
posted @ 2019-04-07 16:21 WAKBGAN 阅读(533) 评论(0) 推荐(0) 编辑
摘要: 链接:https://ac.nowcoder.com/acm/contest/553/D来源:牛客网 题目描述 Chino的数学很差,因此Cocoa非常担心。今天,Cocoa要教Chino解不定方程。 众所周知,不定方程的解有0个或者若干个。 给出方程: Cocoa想知道这个不定方程的正整数解和非负 阅读全文
posted @ 2019-04-07 16:14 WAKBGAN 阅读(298) 评论(0) 推荐(0) 编辑
摘要: 链接:https://ac.nowcoder.com/acm/contest/553/C来源:牛客网 题目描述 Chino的数学很差,因此Cocoa非常担心。今天,Cocoa准备教Chino和排队有关的问题。 我们总是会学各种排列组合的问题,那些题目大多数都是套路。而Cocoa不喜欢套路。 通常来说 阅读全文
posted @ 2019-04-06 23:12 WAKBGAN 阅读(382) 评论(0) 推荐(0) 编辑
上一页 1 ··· 7 8 9 10 11 12 13 14 15 ··· 20 下一页