telegraph.cpp: In function 'int main()':
telegraph.cpp:31:3: warning: this 'if' clause does not guard... [-Wmisleading-indentation]
if(j) ans+=mx;if(j && cnt==n) cyc=1;
^~
telegraph.cpp:31:17: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
if(j) ans+=mx;if(j && cnt==n) cyc=1;
^~
telegraph.cpp:12:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%i",&n);
~~~~~^~~~~~~~~
telegraph.cpp:14:71: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
for(int i=1;i<=n;i++) scanf("%i %i",&a[i],&c[i]),E[a[i]].pb({c[i],i}),sum+=c[i];
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~