上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 29 下一页
摘要: Berland hasncities, some of them are connected by bidirectional roads. For each road we know whether it is asphalted or not.The King of Berland Valera II wants to asphalt all roads of Berland, for that he gathered a group of workers. Every day Valera chooses exactly one city and orders the crew to a 阅读全文
posted @ 2013-11-01 13:44 Oyking 阅读(631) 评论(0) 推荐(0) 编辑
摘要: DescriptionBackgroundRegardless of the fact, that Vologda could not get rights to hold the Winter Olympic games of 20**, it is well-known, that the ci... 阅读全文
posted @ 2013-10-29 13:33 Oyking 阅读(588) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionMost of us know that in the game called DotA(Defense of the Ancient), Pudge is a strong hero in the first period of the game. When the game goes to end however, Pudge is not a strong hero any more.So Pudge’s teammates give him a new assignment—Eat the Trees!The trees are in a rect 阅读全文
posted @ 2013-10-27 18:52 Oyking 阅读(431) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionPeer-to-peer(P2P) computing technology has been widely used on the Internet to exchange data. A lot of P2P file sharing systems exist and gain much popularity in nowadays.Let's consider a simplified model of P2P file sharing system: There are many computers in the system, and 阅读全文
posted @ 2013-10-26 14:17 Oyking 阅读(324) 评论(0) 推荐(0) 编辑
摘要: Description“Be subtle! Be subtle! And use your spies for every kind of business. ”― Sun Tzu“A spy with insufficient ability really sucks”― An anonymous general who lost the warYou, a general, following Sun Tzu’s instruction, make heavy use of spies and agents to gain information secretly in order to 阅读全文
posted @ 2013-10-19 13:43 Oyking 阅读(281) 评论(0) 推荐(0) 编辑
摘要: DescriptionP. T. Tigris is a student currently studying graph theory. One day, when he was studying hard, GS appeared around the corner shyly and came... 阅读全文
posted @ 2013-10-18 20:42 Oyking 阅读(314) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionIn this problem, you are given several strings that contain only digits from '0' to '9', inclusive.An example is shown below.101123The set S of strings is consists of the N strings given in the input file, and all the possible substrings of each one of them.It' 阅读全文
posted @ 2013-10-06 22:16 Oyking 阅读(328) 评论(0) 推荐(0) 编辑
摘要: A string is finite sequence of characters over a non-empty finite set Σ.In this problem, Σ is the set of lowercase letters.Substring, also called factor, is a consecutive sequence of characters occurrences at least once in a string.Now your task is a bit harder, for some given strings, find the leng 阅读全文
posted @ 2013-10-06 16:33 Oyking 阅读(470) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionThere's a queue obeying the first in first out rule. Each time you can either push a number into the queue (+i), or pop a number out from the queue (-i). After a series of operation, you get a sequence (e.g. +1 -1 +2 +4 -2 -4). We call this sequence a queue sequence.Now you ar 阅读全文
posted @ 2013-10-05 18:27 Oyking 阅读(266) 评论(0) 推荐(0) 编辑
摘要: Problem DescriptionA password locker with N digits, each digit can be rotated to 0-9 circularly.You can rotate 1-3 consecutive digits up or down in one step.For examples:567890 -> 567901 (by rotating the last 3 digits up)000000 -> 000900 (by rotating the 4th digit down)Given the current state 阅读全文
posted @ 2013-10-03 21:28 Oyking 阅读(393) 评论(0) 推荐(0) 编辑
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 29 下一页