10308专题

UVa 10308 Roads in the North 树的直径

题目来源:UVa 10308 Roads in the North 题意:求距离最远的2点之间的距离 思路:裸的树的直径 或者树形DP #include <cstdio>#include <cstring>#include <queue>using namespace std;const int maxn = 100010;struct node{int to, w;node()