race.cpp:6:1: error: 'vector' does not name a type
6 | vector<pair<int, int>> a[N];
| ^~~~~~
race.cpp: In function 'void cntSize(int, int)':
race.cpp:11:30: error: 'a' was not declared in this scope
11 | for (int i = 0; i < (int)a[u].size(); i++)
| ^
race.cpp: In function 'int centroid(int, int, int)':
race.cpp:22:30: error: 'a' was not declared in this scope
22 | for (int i = 0; i < (int)a[u].size(); i++)
| ^
race.cpp: In function 'void cal(int, int, int, int, int)':
race.cpp:34:15: error: 'min' was not declared in this scope
34 | ans = min(ans, h+f[k-dis]);
| ^~~
race.cpp:35:19: error: 'min' was not declared in this scope
35 | else f[dis] = min(f[dis], h);
| ^~~
race.cpp:36:30: error: 'a' was not declared in this scope
36 | for (int i = 0; i < (int)a[u].size(); i++)
| ^
race.cpp:40:20: error: 'w' was not declared in this scope
40 | cal(v, dis+w, mode, u, h+1);
| ^
race.cpp: In function 'void reset(int, int, int)':
race.cpp:48:30: error: 'a' was not declared in this scope
48 | for (int i = 0; i < (int)a[u].size(); i++)
| ^
race.cpp:52:22: error: 'w' was not declared in this scope
52 | reset(v, dis+w, u);
| ^
race.cpp: In function 'void decompose(int)':
race.cpp:62:30: error: 'a' was not declared in this scope
62 | for (int i = 0; i < (int)a[root].size(); i++)
| ^
race.cpp:66:16: error: 'w' was not declared in this scope
66 | cal(v, w, 0);
| ^
race.cpp:70:30: error: 'a' was not declared in this scope
70 | for (int i = 0; i < (int)a[root].size(); i++)
| ^
race.cpp:74:18: error: 'w' was not declared in this scope
74 | reset(v, w);
| ^
race.cpp:77:30: error: 'a' was not declared in this scope
77 | for (int i = 0; i < (int)a[root].size(); i++)
| ^
race.cpp: In function 'int best_path(int, int, int (*)[2], int*)':
race.cpp:86:5: error: 'a' was not declared in this scope
86 | a[H[i][0]].push_back({H[i][1], L[i]});
| ^