fun.cpp: In function 'std::vector<int> createFunTour(int, int)':
fun.cpp:38:16: warning: comparison of integer expressions of different signedness: 'll' {aka 'int'} and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
38 | for (i = 1; i < dis.size(); i++) {
| ~~^~~~~~~~~~~~
fun.cpp:84:76: warning: comparison of integer expressions of different signedness: 'long unsigned int' and 'int' [-Wsign-compare]
84 | if (2 * max({ subtree[0].size(), subtree[1].size(), subtree[2].size() }) >= N - 1) {
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
fun.cpp:88:21: warning: comparison of integer expressions of different signedness: 'll' {aka 'int'} and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
88 | if (a != 0 && mx == subtree[0].size()) na = 0;
| ~~~^~~~~~~~~~~~~~~~~~~~
fun.cpp:89:21: warning: comparison of integer expressions of different signedness: 'll' {aka 'int'} and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
89 | if (a != 1 && mx == subtree[1].size()) na = 1;
| ~~~^~~~~~~~~~~~~~~~~~~~
fun.cpp:90:21: warning: comparison of integer expressions of different signedness: 'll' {aka 'int'} and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
90 | if (a != 2 && mx == subtree[2].size()) na = 2;
| ~~~^~~~~~~~~~~~~~~~~~~~
fun.cpp:106:84: warning: comparison of integer expressions of different signedness: 'long unsigned int' and 'll' {aka 'int'} [-Wsign-compare]
106 | if (chk || 2 * max({ subtree[0].size(), subtree[1].size(), subtree[2].size() }) >= (r)-2) {
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
fun.cpp:110:22: warning: comparison of integer expressions of different signedness: 'll' {aka 'int'} and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
110 | if (a != 0 && mx == subtree[0].size()) na = 0;
| ~~~^~~~~~~~~~~~~~~~~~~~
fun.cpp:111:22: warning: comparison of integer expressions of different signedness: 'll' {aka 'int'} and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
111 | if (a != 1 && mx == subtree[1].size()) na = 1;
| ~~~^~~~~~~~~~~~~~~~~~~~
fun.cpp:112:22: warning: comparison of integer expressions of different signedness: 'll' {aka 'int'} and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
112 | if (a != 2 && mx == subtree[2].size()) na = 2;
| ~~~^~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/10/cassert:44,
from fun.cpp:3:
fun.cpp:118:25: warning: comparison of integer expressions of different signedness: 'std::vector<int>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare]
118 | assert(ans.size() == N);
| ~~~~~~~~~~~^~~~
fun.cpp:144:17: warning: comparison of integer expressions of different signedness: 'll' {aka 'int'} and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
144 | for (i = 0; i < ans.size(); i++) assert(ans[i] != c);
| ~~^~~~~~~~~~~~