stations.cpp: In function 'bool subtask1(std::vector<std::vector<int> >&)':
stations.cpp:23:9: warning: unused variable 'n' [-Wunused-variable]
23 | int n = g.size();
| ^
stations.cpp: In function 'bool subtask2(std::vector<int>&, std::vector<int>&)':
stations.cpp:31:25: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
31 | if (!(u[i]==i+1 && v[i]==i/2 || u[i]==i/2 && v[i]==i+1))
stations.cpp: In function 'bool subtask3(std::vector<std::vector<int> >&)':
stations.cpp:36:9: warning: unused variable 'n' [-Wunused-variable]
36 | int n=g.size(), cnt=0;
| ^
stations.cpp: In function 'std::vector<int> label(int, int, std::vector<int>, std::vector<int>)':
stations.cpp:65:13: warning: unused variable 'prev' [-Wunused-variable]
65 | int prev = node;
| ^~~~
stations.cpp:78:9: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
78 | for(int i=0; i<n; i++)
| ^~~
stations.cpp:80:13: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
80 | labels[root] = 0;
| ^~~~~~
stations.cpp:83:23: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
83 | for(int i=0; i<g[root].size(); i++) {
| ~^~~~~~~~~~~~~~~
stations.cpp: In function 'int find_next_station(int, int, std::vector<int>)':
stations.cpp:101:19: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
101 | for(int i=0; i<c.size(); i++)
| ~^~~~~~~~~
stations.cpp:105:23: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
105 | for(int i=0; i<c.size(); i++)
| ~^~~~~~~~~
stations.cpp:129:1: warning: control reaches end of non-void function [-Wreturn-type]
129 | }
| ^
stations.cpp: At global scope:
stations.cpp:15:18: warning: 'w' defined but not used [-Wunused-variable]
15 | static int s, t, w;
| ^
stations.cpp:15:15: warning: 't' defined but not used [-Wunused-variable]
15 | static int s, t, w;
| ^
stations.cpp:15:12: warning: 's' defined but not used [-Wunused-variable]
15 | static int s, t, w;
| ^
stations.cpp:11:21: warning: 'q' defined but not used [-Wunused-variable]
11 | static int r, n, k, q;
| ^
stations.cpp:11:18: warning: 'k' defined but not used [-Wunused-variable]
11 | static int r, n, k, q;
| ^
stations.cpp:11:15: warning: 'n' defined but not used [-Wunused-variable]
11 | static int r, n, k, q;
| ^
stations.cpp:11:12: warning: 'r' defined but not used [-Wunused-variable]
11 | static int r, n, k, q;
| ^
stations.cpp:10:12: warning: 'max_label' defined but not used [-Wunused-variable]
10 | static int max_label = 0;
| ^~~~~~~~~