/in/foo.cc: In function 'int main()':
/in/foo.cc:76:6: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
for(int i=1;i<=n;i++)
^~~
/in/foo.cc:79:5: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'for'
for(int c=1;c<=6;c++)
^~~
/in/foo.cc:44:31: warning: variable 'ans' set but not used [-Wunused-but-set-variable]
double l=0,r=n/(1.0+P*n),mid,ans;
^~~
/in/foo.cc:94:23: warning: 'mid' may be used uninitialized in this function [-Wmaybe-uninitialized]
printf("%.3lf\n",mid);
^