islands.cpp:22:10: error: 'MAXN' was not declared in this scope
22 | bool bio[MAXN];
| ^~~~
islands.cpp:23:8: error: 'MAXN' was not declared in this scope
23 | int to[MAXN], w[MAXN];
| ^~~~
islands.cpp:23:17: error: 'MAXN' was not declared in this scope
23 | int to[MAXN], w[MAXN];
| ^~~~
islands.cpp:24:6: error: 'MAXN' was not declared in this scope
24 | vi g[MAXN];
| ^~~~
islands.cpp: In function 'int ciklus(int)':
islands.cpp:29:5: error: 'bio' was not declared in this scope
29 | if(bio[u]) return u;
| ^~~
islands.cpp:30:2: error: 'bio' was not declared in this scope
30 | bio[u] = 1;
| ^~~
islands.cpp:31:17: error: 'to' was not declared in this scope; did you mean 'tm'?
31 | int v = ciklus(to[u]);
| ^~
| tm
islands.cpp:34:8: error: 'w' was not declared in this scope
34 | s.PB(w[u]);
| ^
islands.cpp: In function 'll dfs(int)':
islands.cpp:44:2: error: 'bio' was not declared in this scope
44 | bio[u] = 1;
| ^~~
islands.cpp:45:14: error: 'g' was not declared in this scope
45 | for(int x : g[u]){
| ^
islands.cpp:47:15: error: 'w' was not declared in this scope
47 | ll ch = (ll)w[x] + dfs(x);
| ^
islands.cpp: In function 'void solve()':
islands.cpp:75:26: error: 'to' was not declared in this scope; did you mean 'tm'?
75 | FOR(i, 1, n + 1) cin >> to[i] >> w[i], g[to[i]].PB(i);
| ^~
| tm
islands.cpp:75:35: error: 'w' was not declared in this scope
75 | FOR(i, 1, n + 1) cin >> to[i] >> w[i], g[to[i]].PB(i);
| ^
islands.cpp:75:41: error: 'g' was not declared in this scope
75 | FOR(i, 1, n + 1) cin >> to[i] >> w[i], g[to[i]].PB(i);
| ^
islands.cpp:76:23: error: 'bio' was not declared in this scope
76 | FOR(i, 1, n + 1) if(!bio[i]) ret = 0, resi(i), ans += ret;
| ^~~