foo.cc: In function 'int main()':
foo.cc:37:18: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
long long mid=l+r>>1;
~^~
foo.cc:44:4: error: 'ans' was not declared in this scope
ans=mid;
^~~
foo.cc:44:4: note: suggested alternative: 'abs'
ans=mid;
^~~
abs
foo.cc:49:8: error: 'ans' was not declared in this scope
cout<<ans;
^~~
foo.cc:49:8: note: suggested alternative: 'abs'
cout<<ans;
^~~
abs
foo.cc:29:8: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&a[i]);
~~~~~^~~~~~~~~~~~
自豪的采用HydroJudge(https://github.com/hydro-dev/Hydro)进行评测。