(int u)
| 282 | } |
| 283 | |
| 284 | public static long compute(int u) { |
| 285 | long ans = query(u); |
| 286 | for (int e = head[u]; e > 0; e = nxt[e]) { |
| 287 | int v = to[e]; |
| 288 | if (query(v) < ans) { |
| 289 | return compute(cent[e]); |
| 290 | } |
| 291 | } |
| 292 | return ans; |
| 293 | } |
| 294 | |
| 295 | public static void main(String[] args) throws Exception { |
| 296 | FastReader in = new FastReader(System.in); |