Time Limit: 3000/1500 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 354 Accepted Submission(s): 100 Problem Description ZYB has a tree with N nodes,now he wants you to solve the numbers of nodes distanced no m…
ZYB's Tree Time Limit: 3000/1500 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 400 Accepted Submission(s): 114 Problem Description ZYB has a tree with N nodes,now he wants you to solve the numbers of nodes dis…
题目链接: Magic boy Bi Luo with his excited tree Time Limit: 8000/4000 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 1037 Accepted Submission(s): 298 Problem Description Bi Luo is a magic boy, he also has a migic…
Appleman has a tree with n vertices. Some of the vertices (at least one) are colored black and other vertices are colored white. Consider a set consisting of k (0 ≤ k < n) edges of Appleman's tree. If Appleman deletes these edges from the tree, then…
题目链接: http://codeforces.com/contest/161/problem/D D. Distance in Tree time limit per test 3 secondsmemory limit per test 512 megabytes 问题描述 A tree is a connected graph that doesn't contain any cycles. The distance between two vertices of a tree is th…