摘要:
题目 Chosen Problem Solving and Program design as an optional course, you are required to solve all kinds of problems. Here, we get a new problem. There 阅读全文
摘要:
题目 A rooted tree is a well-known data structure in computer science and engineering. An example is shown below: In the figure, each node is labeled wi 阅读全文
摘要:
题目 Write a program that takes as input a rooted tree and a list of pairs of vertices. For each pair (u,v) the program determines the closest common an 阅读全文
摘要:
题目 Good morning, agent W-12. Your mission, should you choose to accept it, is as follows. We are infiltrating the ever so insidious Association of Cha 阅读全文
摘要:
题目 One cow from each of N farms (1 ≤ N ≤ 1000) conveniently numbered 1..N is going to attend the big cow party to be held at farm #X (1 ≤ X ≤ N). A to 阅读全文
摘要:
题目 In Land waterless, water is a very limited resource. People always fight for the biggest source of water. Given a sequence of water sources with a1 阅读全文
摘要:
题目 For the daily milking, Farmer John's N cows (1 ≤ N ≤ 50,000) always line up in the same order. One day Farmer John decides to organize a game of Ul 阅读全文