foo.cc: In function 'int main()':
foo.cc:21:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
21 | scanf("%d", &n);
| ~~~~~^~~~~~~~~~
foo.cc:22:39: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
22 | for (int i = 1; i <= n; ++i) scanf("%d", a + i);
| ~~~~~^~~~~~~~~~~~~
foo.cc:25:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
25 | scanf("%d", &m);
| ~~~~~^~~~~~~~~~
foo.cc:28:14: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
28 | scanf("%d%d", &l, &r);
| ~~~~~^~~~~~~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务