garden.cpp:2:11: error: 'nmax' was not declared in this scope
2 | int nextv[nmax * 2], cnt[nmax * 2];
| ^~~~
garden.cpp:2:26: error: 'nmax' was not declared in this scope
2 | int nextv[nmax * 2], cnt[nmax * 2];
| ^~~~
garden.cpp:3:13: error: 'nmax' was not declared in this scope
3 | int visited[nmax * 2];
| ^~~~
garden.cpp:6:11: error: 'nmax' was not declared in this scope
6 | int cycle[nmax * 2], dist1[nmax * 2], dist2[nmax * 2];
| ^~~~
garden.cpp:6:28: error: 'nmax' was not declared in this scope
6 | int cycle[nmax * 2], dist1[nmax * 2], dist2[nmax * 2];
| ^~~~
garden.cpp:6:45: error: 'nmax' was not declared in this scope
6 | int cycle[nmax * 2], dist1[nmax * 2], dist2[nmax * 2];
| ^~~~
garden.cpp: In function 'void fill_cycle_dist(int)':
garden.cpp:10:18: error: 'nextv' was not declared in this scope
10 | int nv = nextv[v];
| ^~~~~
garden.cpp:11:19: error: 'cycle' was not declared in this scope
11 | int cur = cycle[v] - 1;
| ^~~~~
garden.cpp:13:13: error: 'dist1' was not declared in this scope
13 | dist1[nv] = cur;
| ^~~~~
garden.cpp:19:18: error: 'nextv' was not declared in this scope
19 | int nv = nextv[v];
| ^~~~~
garden.cpp:20:19: error: 'cycle' was not declared in this scope
20 | int cur = cycle[v] - 1;
| ^~~~~
garden.cpp:22:13: error: 'dist2' was not declared in this scope
22 | dist2[nv] = cur;
| ^~~~~
garden.cpp: In function 'void dfs(int)':
garden.cpp:31:14: error: 'nextv' was not declared in this scope
31 | int nv = nextv[v];
| ^~~~~
garden.cpp:33:9: error: 'dist1' was not declared in this scope
33 | dist1[v] = 0;
| ^~~~~
garden.cpp:35:9: error: 'dist2' was not declared in this scope
35 | dist2[v] = 0;
| ^~~~~
garden.cpp:36:5: error: 'visited' was not declared in this scope
36 | visited[v] = 1;
| ^~~~~~~
garden.cpp:38:12: error: 'dist1' was not declared in this scope
38 | if(dist1[nv] != -1)
| ^~~~~
garden.cpp:40:12: error: 'dist2' was not declared in this scope
40 | if(dist2[nv] != -1)
| ^~~~~
garden.cpp:52:9: error: 'cycle' was not declared in this scope
52 | cycle[v] = len;
| ^~~~~
garden.cpp:63:8: error: 'cycle' was not declared in this scope
63 | if(cycle[v]) {
| ^~~~~
garden.cpp:67:8: error: 'dist1' was not declared in this scope
67 | if(dist1[nv] != -1)
| ^~~~~
garden.cpp:69:8: error: 'dist2' was not declared in this scope
69 | if(dist2[nv] != -1)
| ^~~~~
garden.cpp: In function 'void count_routes(int, int, int, int (*)[2], int, int*)':
garden.cpp:76:10: error: 'nextv' was not declared in this scope
76 | fill(nextv, nextv + nmax * 2, -1);
| ^~~~~
garden.cpp:76:25: error: 'nmax' was not declared in this scope
76 | fill(nextv, nextv + nmax * 2, -1);
| ^~~~
garden.cpp:76:5: error: 'fill' was not declared in this scope
76 | fill(nextv, nextv + nmax * 2, -1);
| ^~~~
garden.cpp:77:10: error: 'dist1' was not declared in this scope
77 | fill(dist1, dist1 + nmax * 2, -1);
| ^~~~~
garden.cpp:78:10: error: 'dist2' was not declared in this scope
78 | fill(dist2, dist2 + nmax * 2, -1);
| ^~~~~
garden.cpp:79:10: error: 'cnt' was not declared in this scope; did you mean 'int'?
79 | fill(cnt, cnt + nmax * 2, 0);
| ^~~
| int
garden.cpp:80:10: error: 'cycle' was not declared in this scope
80 | fill(cycle, cycle + nmax * 2, 0);
| ^~~~~
garden.cpp:81:10: error: 'visited' was not declared in this scope
81 | fill(visited, visited + nmax * 2, 0);
| ^~~~~~~
garden.cpp:124:9: error: 'answer' was not declared in this scope
124 | answer(ans);
| ^~~~~~