上一页 1 ··· 3 4 5 6 7 8 9 10 下一页
摘要: Problem Description Kayaking is playing a puzzle game containing n different blocks. He marks the blocks with integers from 1 to n, which show the blo 阅读全文
posted @ 2019-04-18 20:05 陈墨cacm 阅读(697) 评论(0) 推荐(0) 编辑
摘要: 题目链接 :http://poj.org/problem?id=3268 Description One cow from each of N farms (1 ≤ N ≤ 1000) conveniently numbered 1..N is going to attend the big cow 阅读全文
posted @ 2019-04-10 09:23 陈墨cacm 阅读(141) 评论(0) 推荐(0) 编辑
摘要: 题目链接 : http://poj.org/problem?id=2253; 思路:这个题主要是理解了意思就行,题目意思是有两只青蛙和若干块石头,现在已知这些东西的坐标,两只青蛙A坐标和青蛙B坐标是第一个和第二个坐标,现在A青蛙想要到B青蛙那里去,并且A青蛙可以借助任意石头的跳跃,而从A到B有若干通 阅读全文
posted @ 2019-04-09 20:40 陈墨cacm 阅读(110) 评论(0) 推荐(0) 编辑
摘要: 题目链接 https://cn.vjudge.net/problem/17712/origin Andrew is working as system administrator and is planning to establish a new network in his company. T 阅读全文
posted @ 2019-04-02 11:42 陈墨cacm 阅读(136) 评论(0) 推荐(0) 编辑
摘要: ***姹接到一个任务,为税务部门调查一位商人的账本,看看账本是不是伪造的。账本上记录了n个月以来的收入情况,其中第i 个月的收入额为Ai(i=1,2,3...n-1,n), 。当 Ai大于0时表示这个月盈利Ai 元,当 Ai小于0时表示这个月亏损Ai 元。所谓一段时间内的总收入,就是这段时间内每个月的收 阅读全文
posted @ 2019-03-29 09:18 陈墨cacm 阅读(91) 评论(0) 推荐(0) 编辑
摘要: At the big break Nastya came to the school dining room. There are nn pupils in the school, numbered from 11 to nn. Unfortunately, Nastya came pretty l 阅读全文
posted @ 2019-03-25 20:55 陈墨cacm 阅读(102) 评论(0) 推荐(0) 编辑
摘要: Polycarp plays "Game 23". Initially he has a number nn and his goal is to transform it to m. In one move, he can multiply n by 22 or multiply n by 33. 阅读全文
posted @ 2019-03-23 16:43 陈墨cacm 阅读(217) 评论(0) 推荐(0) 编辑
摘要: 问题描述 Fibonacci数列的递推公式为:Fn=Fn-1+Fn-2,其中F1=F2=1。 当n比较大时,Fn也非常大,现在我们想知道,Fn除以10007的余数是多少。 Fibonacci数列的递推公式为:Fn=Fn-1+Fn-2,其中F1=F2=1。 当n比较大时,Fn也非常大,现在我们想知道, 阅读全文
posted @ 2019-03-21 19:25 陈墨cacm 阅读(448) 评论(0) 推荐(0) 编辑
摘要: 做法:做法其实很简单,首先将2到n范围内的整数写下来,其中2是最小的素数。将表中所有的2的倍数划去,表中剩下的最小的数字就是3,他不能被更小的数整除,所以3是素数。再将表中所有的3的倍数划去……以此类推,如果表中剩余的最小的数是m,那么m就是素数。然后将表中所有m的倍数划去,像这样反复操作,就能依次 阅读全文
posted @ 2019-03-20 19:43 陈墨cacm 阅读(326) 评论(0) 推荐(0) 编辑
摘要: 一、巴什博弈(Bash Game) 只有一堆n个物品,两个人从轮流中取出(1~m)个;最后取光者胜。 考虑到 若n=m+1 那么 第一个人不论如何取都不能取胜。 进一步我们发现 若 n=k*(m+1)+r; 先取者拿走 r 个,那么后者再拿(1~m)个 n=(k-1)*(m+1)+s; 先取者再拿走 阅读全文
posted @ 2019-02-26 17:05 陈墨cacm 阅读(150) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 下一页