foo.cc: In function 'int read()':
foo.cc:26:2: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
for (c=gc;!isdigit(c);c=gc) if (c=='-') f=-1; x=c-'0';
^~~
foo.cc:26:48: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
for (c=gc;!isdigit(c);c=gc) if (c=='-') f=-1; x=c-'0';
^
foo.cc: In function 'int main()':
foo.cc:17:20: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
#define rep(i,s,n) for (register int i=s;i<=n;i++)
^
foo.cc:61:2: note: in expansion of macro 'rep'
rep(i,1,n) ans+=s[i]/v[i]; printf("%.11lf\n",ans);
^~~
foo.cc:61:29: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
rep(i,1,n) ans+=s[i]/v[i]; printf("%.11lf\n",ans);
^~~~~~
foo.cc:55:17: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
n=read(); scanf("%lf",&Eu); rep(i,1,n) scanf("%lf%lf%lf",&s[i],&k[i],&u[i]);
~~~~~^~~~~~~~~~~
foo.cc:55:46: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
n=read(); scanf("%lf",&Eu); rep(i,1,n) scanf("%lf%lf%lf",&s[i],&k[i],&u[i]);
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
foo.cc: In function 'double solve(int, double)':
foo.cc:42:9: warning: 'mid' may be used uninitialized in this function [-Wmaybe-uninitialized]
return mid;
^~~
[Hydro](https://hydro.ac)提供评测服务