title: WOJ1024 (POJ1985+POJ2631) Exploration 树/BFS date: 2020-03-20 10:43:00 categories: acm tags: [acm,woj,图论] 用到了树的 直径 1 描述 Tom is an explorer and now he is in a mysterious cave. He finds that there are lots of rooms in it. You are ensured that the…
题目如下: A graph which is connected and acyclic can be considered a tree. The height of the tree depends on the selected root. Now you are supposed to find the root that results in a highest tree. Such a root is called the deepest root. Input Specificat…
题目描述 You are given an undirected connected weighted graph consisting of n n n vertices and m m m edges. Let's denote the length of the shortest path from vertex 1 1 1 to vertex i i i as di d_i di . You have to erase some edges of the graph so that a…