04 2016 档案

摘要:Description Edward is the headmaster of Marjar University. He is enthusiastic about chess and often plays chess with his friends. What's more, he bought a large decorativ... 阅读全文
posted @ 2016-04-20 14:20 ZhMZ 阅读(359) 评论(0) 推荐(0)
摘要:Description 吉哥又想出了一个新的完美队形游戏! 假设有n个人按顺序站在他的面前,他们的身高分别是h[1], h[2] ... h[n],吉哥希望从中挑出一些人,让这些人形成一个新的队形,新的队形若满足以下三点要求,则就是新的完美队形: 1、挑出的人保持原队形的相对顺序不变,且必须... 阅读全文
posted @ 2016-04-14 15:53 ZhMZ 阅读(351) 评论(0) 推荐(0)
摘要:Manacher算讲解:(讲得很好,花十几分钟看一下原理然后自己敲模板) http://www.cnblogs.com/biyeymyhjob/archive/2012/10/04/2711527.html 看了上面的讲解,O(n)回文子串(Manacher)算法就大致了解了它的原理,这倒是个比较简单的知识点。 下面看模板题: Desc... 阅读全文
posted @ 2016-04-14 13:47 ZhMZ 阅读(432) 评论(0) 推荐(0)
摘要:Description Hzz loves aeroplane chess very much. The chess map contains N+1 grids labeled from 0 to N. Hzz starts at grid 0. For each step he throws a dice(a dice have si... 阅读全文
posted @ 2016-04-13 19:31 ZhMZ 阅读(221) 评论(0) 推荐(0)
摘要:Description I used to think I could be anything, but now I know that I couldn't do anything. So I started traveling. The nation looks like a connected bidirecti... 阅读全文
posted @ 2016-04-12 21:37 ZhMZ 阅读(467) 评论(0) 推荐(0)
摘要:Description In the battlefield , an effective way to defeat enemies is to break their communication system. The information department told you that there are n... 阅读全文
posted @ 2016-04-09 20:23 ZhMZ 阅读(216) 评论(0) 推荐(0)
摘要:Description For the hope of a forever love, Steven is planning to send a ring to Jane with a romantic string engraved on. The string's length should not exceed N. The car... 阅读全文
posted @ 2016-04-09 19:11 ZhMZ 阅读(200) 评论(0) 推荐(0)
摘要:Description Biologists finally invent techniques of repairing DNA that contains segments causing kinds of inherited diseases. For the sake of simplicity, a DNA is represe... 阅读全文
posted @ 2016-04-09 14:14 ZhMZ 阅读(292) 评论(0) 推荐(0)
摘要:Description There is going to be a party to celebrate the 80-th Anniversary of the Ural State University. The University has a hierarchical structure of employees. It mea... 阅读全文
posted @ 2016-04-06 19:32 ZhMZ 阅读(170) 评论(0) 推荐(0)
摘要:Description ACboy很喜欢玩一种战略游戏,在一个地图上,有N座城堡,每座城堡都有一定的宝物,在每次游戏中ACboy允许攻克M个城堡并获得里面的宝物。但由于地理位置原因,有些城堡不能直接攻克,要攻克这些城堡必须先攻克其他某一个特定的城堡。你能帮ACboy算出要获得尽量多的宝物应该攻克哪M个城堡吗? Input... 阅读全文
posted @ 2016-04-06 18:55 ZhMZ 阅读(188) 评论(0) 推荐(0)
摘要:Description Bob wants to hold a race to encourage people to do sports. He has got trouble in choosing the route. There are N houses and N - 1 roads in his village. Each r... 阅读全文
posted @ 2016-04-06 17:16 ZhMZ 阅读(134) 评论(0) 推荐(0)
摘要:Description Wind loves pretty dogs very much, and she has n pet dogs. So Jiajia has to feed the dogs every day for Wind. Jiajia loves Wind, but not the dogs, so Jiajia us... 阅读全文
posted @ 2016-04-06 15:39 ZhMZ 阅读(179) 评论(0) 推荐(0)
摘要:Description Shaolin temple is very famous for its Kongfu monks.A lot of young men go to Shaolin temple every year, trying to be a monk there. The master of Shaolin evalua... 阅读全文
posted @ 2016-04-05 21:18 ZhMZ 阅读(225) 评论(0) 推荐(0)
摘要:Description Nowadays, there are more and more challenge game on TV such as 'Girls, Rush Ahead'. Now, you participate int a game like this. There are N rooms. The connecti... 阅读全文
posted @ 2016-04-04 20:40 ZhMZ 阅读(164) 评论(0) 推荐(0)
摘要:Description Little sun is an artist. Today he is playing mahjong alone. He suddenly feels that the tree in the yard doesn't look good. So he wants to decorate the tree.(T... 阅读全文
posted @ 2016-04-04 14:21 ZhMZ 阅读(153) 评论(0) 推荐(0)
摘要:Description It's election time in Berland. The favorites are of course parties of zublicanes and mumocrates. The election campaigns of both parties include numerous demon... 阅读全文
posted @ 2016-04-03 11:56 ZhMZ 阅读(1408) 评论(0) 推荐(0)