0_0_36332647_26525\Main.java:1: 错误: 非法字符: '#'
#include <iostream>
^
0_0_36332647_26525\Main.java:1: 错误: 需要class, interface或enum
#include <iostream>
^
0_0_36332647_26525\Main.java:2: 错误: 非法字符: '#'
#include <cstdio>
^
0_0_36332647_26525\Main.java:3: 错误: 非法字符: '#'
#include <algorithm>
^
0_0_36332647_26525\Main.java:4: 错误: 非法字符: '#'
#include <cstring>
^
0_0_36332647_26525\Main.java:6: 错误: 需要class, interface或enum
const int maxed = 100000 + 10;
^
0_0_36332647_26525\Main.java:7: 错误: 需要class, interface或enum
struct E
^
0_0_36332647_26525\Main.java:10: 错误: 需要class, interface或enum
}e[maxed * 2];
^
0_0_36332647_26525\Main.java:11: 错误: 需要class, interface或enum
int n, m, ans, head[maxed];
^
0_0_36332647_26525\Main.java:12: 错误: 需要class, interface或enum
int link_cnt, d[maxed], gen[maxed], link_[maxed], son[maxed], size_[maxed], top[maxed], l_[maxed];
^
0_0_36332647_26525\Main.java:13: 错误: 需要class, interface或enum
int cnt_a, cnt_b, A[maxed], B[maxed];
^
0_0_36332647_26525\Main.java:14: 错误: 需要class, interface或enum
int main()
^
0_0_36332647_26525\Main.java:17: 错误: 需要class, interface或enum
void slove_1(int u, int fa);
^
0_0_36332647_26525\Main.java:18: 错误: 需要class, interface或enum
void slove_2(int u, int fa, int ufa);
^
0_0_36332647_26525\Main.java:19: 错误: 需要class, interface或enum
int find_lca(int x, int y);
^
0_0_36332647_26525\Main.java:20: 错误: 需要class, interface或enum
while (scanf("%d%d", &n, &m) != EOF) {
^
0_0_36332647_26525\Main.java:22: 错误: 需要class, interface或enum
memset(head, -1, sizeof(head));
^
0_0_36332647_26525\Main.java:23: 错误: 需要class, interface或enum
int a, b;
^
0_0_36332647_26525\Main.java:24: 错误: 需要class, interface或enum
for (int i = 1; i <= n - 1; ++i) {
^
0_0_36332647_26525\Main.java:24: 错误: 需要class, interface或enum
for (int i = 1; i <= n - 1; ++i) {
^
0_0_36332647_26525\Main.java:24: 错误: 需要class, interface或enum
for (int i = 1; i <= n - 1; ++i) {
^
0_0_36332647_26525\Main.java:26: 错误: 需要class, interface或enum
add_(a, b);
^
0_0_36332647_26525\Main.java:27: 错误: 需要class, interface或enum
add_(b, a);
^
0_0_36332647_26525\Main.java:28: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:30: 错误: 需要class, interface或enum
slove_1(1, 1);
^
0_0_36332647_26525\Main.java:31: 错误: 需要class, interface或enum
slove_2(1, 1, 1);
^
0_0_36332647_26525\Main.java:32: 错误: 需要class, interface或enum
int max_;
^
0_0_36332647_26525\Main.java:33: 错误: 需要class, interface或enum
while (m--) {
^
0_0_36332647_26525\Main.java:35: 错误: 需要class, interface或enum
for (int i = 1; i <= cnt_a; ++i) {
^
0_0_36332647_26525\Main.java:35: 错误: 需要class, interface或enum
for (int i = 1; i <= cnt_a; ++i) {
^
0_0_36332647_26525\Main.java:35: 错误: 需要class, interface或enum
for (int i = 1; i <= cnt_a; ++i) {
^
0_0_36332647_26525\Main.java:37: 错误: 需要class, interface或enum
A[i] = link_[A[i]];
^
0_0_36332647_26525\Main.java:38: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:40: 错误: 需要class, interface或enum
for (int i = 1; i <= cnt_b; ++i) {
^
0_0_36332647_26525\Main.java:40: 错误: 需要class, interface或enum
for (int i = 1; i <= cnt_b; ++i) {
^
0_0_36332647_26525\Main.java:40: 错误: 需要class, interface或enum
for (int i = 1; i <= cnt_b; ++i) {
^
0_0_36332647_26525\Main.java:42: 错误: 需要class, interface或enum
B[i] = link_[B[i]];
^
0_0_36332647_26525\Main.java:43: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:46: 错误: 需要class, interface或enum
int len = unique(B + 1, B + 1 + cnt_b) - B - 1;
^
0_0_36332647_26525\Main.java:47: 错误: 需要class, interface或enum
max_ = 0;
^
0_0_36332647_26525\Main.java:48: 错误: 需要class, interface或enum
for (int i = 1; i <= cnt_a; ++i) {
^
0_0_36332647_26525\Main.java:48: 错误: 需要class, interface或enum
for (int i = 1; i <= cnt_a; ++i) {
^
0_0_36332647_26525\Main.java:48: 错误: 需要class, interface或enum
for (int i = 1; i <= cnt_a; ++i) {
^
0_0_36332647_26525\Main.java:50: 错误: 需要class, interface或enum
if (wa == len + 1) //{
^
0_0_36332647_26525\Main.java:56: 错误: 需要class, interface或enum
else if (wa == 1) //{
^
0_0_36332647_26525\Main.java:59: 错误: 需要class, interface或enum
else {
^
0_0_36332647_26525\Main.java:61: 错误: 需要class, interface或enum
max_ = max(max_, d[find_lca(l_[B[wa - 1]], l_[A[i]])]);
^
0_0_36332647_26525\Main.java:62: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:65: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:68: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:72: 错误: 需要class, interface或enum
e[ans].bef = head[x];
^
0_0_36332647_26525\Main.java:73: 错误: 需要class, interface或enum
head[x] = ans++;
^
0_0_36332647_26525\Main.java:74: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:78: 错误: 需要class, interface或enum
l_[link_cnt] = u;
^
0_0_36332647_26525\Main.java:79: 错误: 需要class, interface或enum
size_[u] = 1;
^
0_0_36332647_26525\Main.java:80: 错误: 需要class, interface或enum
son[u] = 0;
^
0_0_36332647_26525\Main.java:81: 错误: 需要class, interface或enum
for (int i = head[u]; i != - 1; i = e[i].bef) {
^
0_0_36332647_26525\Main.java:81: 错误: 需要class, interface或enum
for (int i = head[u]; i != - 1; i = e[i].bef) {
^
0_0_36332647_26525\Main.java:81: 错误: 需要class, interface或enum
for (int i = head[u]; i != - 1; i = e[i].bef) {
^
0_0_36332647_26525\Main.java:83: 错误: 需要class, interface或enum
if (v == fa)
^
0_0_36332647_26525\Main.java:85: 错误: 需要class, interface或enum
gen[v] = u;
^
0_0_36332647_26525\Main.java:86: 错误: 需要class, interface或enum
d[v] = d[u] + 1;
^
0_0_36332647_26525\Main.java:87: 错误: 需要class, interface或enum
slove_1(v, u);
^
0_0_36332647_26525\Main.java:88: 错误: 需要class, interface或enum
size_[u] += size_[v];
^
0_0_36332647_26525\Main.java:89: 错误: 需要class, interface或enum
if (!son[u] || size_[v] > size_[son[u]])
^
0_0_36332647_26525\Main.java:91: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:96: 错误: 需要class, interface或enum
if (son[u])
^
0_0_36332647_26525\Main.java:98: 错误: 需要class, interface或enum
for (int i = head[u]; i != -1; i = e[i].bef) {
^
0_0_36332647_26525\Main.java:98: 错误: 需要class, interface或enum
for (int i = head[u]; i != -1; i = e[i].bef) {
^
0_0_36332647_26525\Main.java:98: 错误: 需要class, interface或enum
for (int i = head[u]; i != -1; i = e[i].bef) {
^
0_0_36332647_26525\Main.java:100: 错误: 需要class, interface或enum
if (v == fa || v == ufa || son[u] == v)
^
0_0_36332647_26525\Main.java:102: 错误: 需要class, interface或enum
slove_2(v, u, v);
^
0_0_36332647_26525\Main.java:103: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:108: 错误: 需要class, interface或enum
int f1 = top[x], f2 = top[y];
^
0_0_36332647_26525\Main.java:109: 错误: 需要class, interface或enum
while (f1 != f2) {
^
0_0_36332647_26525\Main.java:112: 错误: 需要class, interface或enum
swap(l, r);
^
0_0_36332647_26525\Main.java:113: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:115: 错误: 需要class, interface或enum
f1 = top[l];
^
0_0_36332647_26525\Main.java:116: 错误: 需要class, interface或enum
}
^
0_0_36332647_26525\Main.java:119: 错误: 需要class, interface或enum
return l;
^
0_0_36332647_26525\Main.java:120: 错误: 需要class, interface或enum
}
^
81 个错误
|