magictree.cpp: In function 'void DFS(int)':
magictree.cpp:18:20: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0 ; i < adj[cur].size() ; i++)
~~^~~~~~~~~~~~~~~~~
magictree.cpp:26:21: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i = 0 ; i < adj[cur].size() ; i++)
~~^~~~~~~~~~~~~~~~~
magictree.cpp: In function 'int main()':
magictree.cpp:35:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d %d %d",&n,&m,&k);
~~~~~^~~~~~~~~~~~~~~~~~~~~
magictree.cpp:40:8: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&p);
~~~~~^~~~~~~~~
magictree.cpp:48:8: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&node);
~~~~~^~~~~~~~~~~~
magictree.cpp:49:8: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d %d",&t[node],&w[node]);
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~