net.cpp: In function 'int main()':
net.cpp:16:17: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
int n; scanf("%d",&n);
~~~~~^~~~~~~~~
net.cpp:19:23: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
int x,y; scanf("%d %d",&x,&y);
~~~~~^~~~~~~~~~~~~~~
net.cpp:25:8: warning: 'firstdfs' may be used uninitialized in this function [-Wmaybe-uninitialized]
dfs(firstdfs,-1);
~~~^~~~~~~~~~~~~