beads.cpp: In function 'void go(int, int)':
beads.cpp:18:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < G[v].size(); ++ i)
~~^~~~~~~~~~~~~
beads.cpp:34:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < G[v].size(); ++ i)
~~^~~~~~~~~~~~~
beads.cpp:17:6: warning: unused variable 'mx1' [-Wunused-variable]
ll mx1 = -2e9, mx2 = -2e9, child = 0, tot = 0;
^~~
beads.cpp:17:18: warning: unused variable 'mx2' [-Wunused-variable]
ll mx1 = -2e9, mx2 = -2e9, child = 0, tot = 0;
^~~
beads.cpp: In function 'void dfs(int, long long int, long long int)':
beads.cpp:49:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < G[v].size(); ++ i)
~~^~~~~~~~~~~~~
beads.cpp:62:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0; i < G[v].size(); ++ i)
~~^~~~~~~~~~~~~
beads.cpp: In function 'int main()':
beads.cpp:74:8: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d", &n);
~~~~~^~~~~~~~~~
beads.cpp:78:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d %d %d", &x, &y, &val);
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~