torrent.cpp: In function 'int dfs1(int, int)':
torrent.cpp:37:15: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
37 | for(int i=0;i<c.size();i++) res = max(res, c[i]+i+1);
| ~^~~~~~~~~
torrent.cpp: In function 'int main()':
torrent.cpp:58:11: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
58 | mid = lo+hi>>1;
| ~~^~~
torrent.cpp:72:29: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
72 | if(testIdx >= 0 && testIdx < path.size()) {
| ~~~~~~~~^~~~~~~~~~~~~
torrent.cpp:77:29: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
77 | if(testIdx >= 0 && testIdx < path.size()) {
| ~~~~~~~~^~~~~~~~~~~~~
torrent.cpp:82:29: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::pair<int, int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
82 | if(testIdx >= 0 && testIdx < path.size()) {
| ~~~~~~~~^~~~~~~~~~~~~
torrent.cpp:42:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
42 | scanf("%d%d%d", &n, &a, &b);
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~
torrent.cpp:45:8: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
45 | scanf("%d%d", &u,&v);
| ~~~~~^~~~~~~~~~~~~~~