随笔分类 - online judge poj
摘要:Distance Queries Description Farmer John's cows refused to run in his marathon since he chose a path much too long for their leisurely lifestyle. He t
阅读全文
摘要:A Simple Problem with Integers Description You have N integers, A1, A2, ... , AN. You need to deal with two kinds of operations. One type of operation
阅读全文
摘要:Nearest Common Ancestors Description A rooted tree is a well-known data structure in computer science and engineering. An example is shown below: In t
阅读全文
摘要:Network Description A Telephone Line Company (TLC) is establishing a new telephone cable network. They are connecting several places numbered by integ
阅读全文
摘要:SPF Description Consider the two networks shown below. Assuming that data moves around these networks only between directly connected nodes on a peer-
阅读全文
摘要:Going from u to v or from v to u? Description In order to make their sons brave, Jiajia and Wind take them to a big cave. The cave has n rooms, and on
阅读全文
摘要:Apple Catching Description It is a little known fact that cows love apples. Farmer John has two apple trees (which are conveniently numbered 1 and 2)
阅读全文
摘要:Popular Cows Description Every cow's dream is to become the most popular cow in the herd. In a herd of N (1 <= N <= 10,000) cows, you are given up to
阅读全文
摘要:The k-th Largest Group Time Limit: 2000MS Memory Limit: 131072K Total Submissions: 8353 Accepted: 2712 Description Newman likes playing with cats. He
阅读全文