foo.c: In function 'main':
foo.c:24:21: warning: implicit declaration of function 'strrev'; did you mean 'strlen'? [-Wimplicit-function-declaration]
24 | int xmin = atoi(strrev(str));
| ^~~~~~
| strlen
foo.c:24:21: warning: passing argument 1 of 'atoi' makes pointer from integer without a cast [-Wint-conversion]
24 | int xmin = atoi(strrev(str));
| ^~~~~~~~~~~
| |
| int
In file included from /nix/store/linb70pgp53f0kygxm5wk163dx22d681-glibc-2.37-45-dev/include/features.h:491,
from /nix/store/linb70pgp53f0kygxm5wk163dx22d681-glibc-2.37-45-dev/include/bits/libc-header-start.h:33,
from /nix/store/linb70pgp53f0kygxm5wk163dx22d681-glibc-2.37-45-dev/include/stdlib.h:26,
from foo.c:1:
/nix/store/linb70pgp53f0kygxm5wk163dx22d681-glibc-2.37-45-dev/include/stdlib.h:362:1: note: expected 'const char *' but argument is of type 'int'
362 | __NTH (atoi (const char *__nptr))
| ^~~~~
/nix/store/3r87a2wq1w4l66wnsm7rqvy608mx23h6-binutils-2.40/bin/ld: /tmp/ccwboESN.o: in function `main':
foo.c:(.text.startup+0x65): undefined reference to `strrev'
collect2: error: ld returned 1 exit status
[Hydro](https://hydro.ac)提供评测服务