原创 1120 Friend Numbers(20 分)(cj)

1120 Friend Numbers(20 分) Two integers are called "friend numbers" if they share the same sum of their digits, and the

原创 1132 Cut Integer (20 分)(cj)

1132 Cut Integer (20 分) Cutting an integer means to cut a K digits lone integer Z into two integers of (K/2) digits lon

原创 1129 Recommendation System (25 分)(cj)

1129 Recommendation System (25 分) Recommendation system predicts the preference that a user would give to an item. Now

原创 1123 Is It a Complete AVL Tree(30 分)(cj)

1123 Is It a Complete AVL Tree(30 分) An AVL tree is a self-balancing binary search tree. In an AVL tree, the heights of

原创 1134 Vertex Cover (25 分)(cj)

1134 Vertex Cover (25 分) A vertex cover of a graph is a set of vertices such that each edge of the graph is incident to

原创 1118 Birds in Forest(25 分)(cj)

1118 Birds in Forest(25 分) Some scientists took pictures of thousands of birds in a forest. Assume that all the birds a

原创 1121 Damn Single(25 分)(cj)

1121 Damn Single(25 分) "Damn Single (單身狗)" is the Chinese nickname for someone who is being single. You are supposed to

原创 1130 Infix Expression(25 分)(cj)

1130 Infix Expression(25 分) Given a syntax tree (binary), you are supposed to output the corresponding infix expression

原创 1116 Come on! Let's C(20 分)(cj)

1116 Come on! Let's C(20 分) "Let's C" is a popular and fun programming contest hosted by the College of Computer Scienc

原创 1122 Hamiltonian Cycle(25 分)(cj)

1122 Hamiltonian Cycle(25 分) The "Hamilton cycle problem" is to find a simple cycle that contains every vertex in a gra

原创 1119 Pre- and Post-order Traversals(30 分)(cj)

1119 Pre- and Post-order Traversals(30 分) Suppose that all the keys in a binary tree are distinct positive integers. A

原创 1117 Eddington Number(25 分)(cj)

1117 Eddington Number(25 分) British astronomer Eddington liked to ride a bike. It is said that in order to show off his

原创 1131 Subway Map (30 分)(cj)

1131 Subway Map (30 分) In the big cities, the subway systems always look so complex to the visitors. To give you some s

原创 1126 Eulerian Path (25 分)(cj)

1126 Eulerian Path (25 分) In graph theory, an Eulerian path is a path in a graph which visits every edge exactly once.

原创 1127 ZigZagging on a Tree(30 分)(cj)

1127 ZigZagging on a Tree(30 分) Suppose that all the keys in a binary tree are distinct positive integers. A unique bin