mousetrap.cpp: In function 'void update(long long int)':
mousetrap.cpp:67:21: warning: comparison of integer expressions of different signedness: 'long long int' and 'std::vector<long long int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
67 | for(int i = k; i<f.size(); i+=i&-i) f[i]++;
| ~^~~~~~~~~
mousetrap.cpp: In function 'int main()':
mousetrap.cpp:101:13: warning: comparison of integer expressions of different signedness: 'long long int' and 'std::vector<long long int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
101 | if(i<path.size()-1) suff[i]+=suff[i+1];
| ~^~~~~~~~~~~~~~
mousetrap.cpp:102:13: warning: comparison of integer expressions of different signedness: 'long long int' and 'std::vector<long long int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
102 | if(i<path.size()-1&&i>0) suff[i]-=1;
| ~^~~~~~~~~~~~~~
mousetrap.cpp:4:35: warning: comparison of integer expressions of different signedness: 'long long int' and 'std::vector<long long int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
4 | #define rep(i,n) for(int i = 0; i < n; i++)
......
106 | rep(i, path.size())
| ~~~~~~~~~~~~~~
mousetrap.cpp:106:5: note: in expansion of macro 'rep'
106 | rep(i, path.size())
| ^~~
mousetrap.cpp:111:40: warning: comparison of integer expressions of different signedness: 'long long int' and 'std::vector<long long int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
111 | if((i>0&&w==path[i-1]||(i+1<path.size()&&w==path[i+1]))||w==t) continue;
| ~~~^~~~~~~~~~~~
mousetrap.cpp:111:20: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
111 | if((i>0&&w==path[i-1]||(i+1<path.size()&&w==path[i+1]))||w==t) continue;
mousetrap.cpp:4:35: warning: comparison of integer expressions of different signedness: 'long long int' and 'std::vector<long long int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
4 | #define rep(i,n) for(int i = 0; i < n; i++)
......
127 | rep(i, path.size())
| ~~~~~~~~~~~~~~
mousetrap.cpp:127:9: note: in expansion of macro 'rep'
127 | rep(i, path.size())
| ^~~