torrent.cpp: In function 'bool chk(int)':
torrent.cpp:16:16: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
16 | for(int j=0;j<t[id[l]].size();j++)
| ~^~~~~~~~~~~~~~~~
torrent.cpp:24:16: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
24 | for(int j=0;j<t[id[r]].size();j++)
| ~^~~~~~~~~~~~~~~~
torrent.cpp: In function 'int main()':
torrent.cpp:39:24: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
39 | if(i!=1)for(int j=0;j<t[id[i]].size();j++)
| ~^~~~~~~~~~~~~~~~
torrent.cpp:46:12: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
46 | int mid=l+r>>1;
| ~^~
torrent.cpp:33:7: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
33 | scanf("%d%d%d",&n,&rt,&p);
| ~~~~~^~~~~~~~~~~~~~~~~~~~
torrent.cpp:34:32: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
34 | for(int i=1,u,v;i<n;i++) scanf("%d%d",&u,&v),e[u].push_back(v),e[v].push_back(u);
| ~~~~~^~~~~~~~~~~~~~