数学
文章平均质量分 70
鸭脖yb
这个作者很懒,什么都没留下…
展开
-
牛客网暑期acm多校训练第4场A题——欧拉降幂+快速幂模板
题目链接A ternary string is a sequence of digits, where each digit is either 0, 1, or 2.Chiaki has a ternary string s which can self-reproduce. Every second, a digit 0 is inserted after every 1 in the ...原创 2018-08-01 11:23:23 · 491 阅读 · 0 评论 -
求组合数 Lightoj1067
Combinations Given n different objects, you want to take k of them. How many ways to can do it?For example, say there are 4 items; you wa...原创 2018-08-07 19:33:46 · 199 阅读 · 0 评论 -
Lucas定理 + 隔板法 HDU3037
Saving Beans Although winter is far away, squirrels have to work day and night to save beans. They need plenty of food to get through those long cold days. After some time the squirrel family thinks...原创 2018-08-07 20:51:11 · 131 阅读 · 0 评论 -
二进制法枚举集合——权利指数 HDU1557
权利指数在选举问题中,总共有n个小团体,每个小团体拥有一定数量的选票数。如果其中m个小团体的票数和超过总票数的一半,则此组合为“获胜联盟”。n个团体可形成若干个获胜联盟。一个小团体要成为一个“关键加入者”的条件是:在其所在的获胜联盟中,如果缺少了这个小团体的加入,则此联盟不能成为获胜联盟...原创 2018-08-12 23:16:12 · 431 阅读 · 0 评论 -
拓展欧几里得——egcd poj2142
The Balance Ms. Iyo Kiffa-Australis has a balance and only two kinds of weights to measure a dose of medicine. For example, to measure 200mg of aspirin ...原创 2018-08-08 10:43:32 · 705 阅读 · 0 评论 -
wustoj 1506 药丸 卡特兰数
Description一个药瓶里装有n颗药丸,每天吃半颗,需要在2n天吃完。每天吃药时,从药瓶中取药,如果取到的药是整颗的,就把它分成两半,吃掉其中的一半,另一半重新放入瓶中;如果取到的是半颗药,则直接吃掉。问共有多少种吃药方法?例如:n=1,则吃药方法有1种(取一颗,取半颗)。n=2,则有2种吃药方法(取一颗,取半颗,取一颗,取半颗;取一颗,取一颗,取半颗,取半颗)。Inpu...原创 2018-08-29 10:42:41 · 392 阅读 · 0 评论 -
wustoj2244数学
TeleportationTime Limit: 1 Sec Description Hovey just learnt a powerful skill from the failurc of his chasing MMs: teleportation. He can teleport from point (x , y) to another point (x',...原创 2018-08-29 16:44:48 · 253 阅读 · 0 评论