foo.cc: In function 'int main()':
foo.cc:37:12: error: expected ';' before ')' token
37 | for (--n)
| ^
| ;
foo.cc:44:4: error: expected primary-expression before 'return'
44 | return 0;
| ^~~~~~
foo.cc:43:20: error: expected ')' before 'return'
43 | printf("%d", a);
| ^
| )
44 | return 0;
| ~~~~~~
foo.cc:37:8: note: to match this '('
37 | for (--n)
| ^
foo.cc:35:9: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
35 | scanf("%d", &n);
| ~~~~~^~~~~~~~~~
foo.cc:36:9: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
36 | scanf("%d", &a);
| ~~~~~^~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务