数论及组合数学
文章平均质量分 78
JJing
小菜鸟的自白。。。O(∩_∩)O~
展开
-
POJ 1942 Paths on a Grid
本来以为是一套高中的数学题,以为找出公式就ok了,结果。。排列还超时。。。另外。。。就是排列要用到double。。。。 DescriptionImagine you are attending your math lesson at school. Once again, yo原创 2011-08-06 15:45:07 · 452 阅读 · 0 评论 -
POJ 3370 Halloween treats
题目大意:输入n,m,以及m个数据,求可被n整除的一个组合。。。由于是任意组合~所以样例不一定是对的~~~ Description Every year there is the same problem at Halloween: Each neighbour is原创 2011-08-09 19:21:41 · 1082 阅读 · 0 评论 -
Multiple of 17
题目大意:所给数n,去掉最后一位数a,并减去5*a所得的值是否能被17整除? Description Theorem: If you drop the last digit d of an integer n (n10), subtract 5d from the remaining integer, then the difference is a multiple of 17 if原创 2012-02-23 18:51:08 · 609 阅读 · 0 评论