foo.cc:31:8: warning: multi-character character constant [-Wmultichar]
31 | printf('%d',ans);
| ^~~~
foo.cc: In function 'int main()':
foo.cc:31:8: error: invalid conversion from 'int' to 'const char*' [-fpermissive]
31 | printf('%d',ans);
| ^~~~
| |
| int
In file included from /nix/store/wy4ywjsch9q2hj5lphqjdg9p2kf7w0ls-gcc-11.3.0/include/c++/11.3.0/cstdio:42,
from foo.cc:2:
/nix/store/iczlqwdj10xiz3mmms6adnra0mn3ljk1-glibc-2.35-224-dev/include/stdio.h:356:43: note: initializing argument 1 of 'int printf(const char*, ...)'
356 | extern int printf (const char *__restrict __format, ...);
| ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
[Hydro](https://hydro.ac)提供评测服务