fork download
  1. #include <stdio.h>
  2.  
  3. int main(void)
  4. {
  5. char[] s = "12345";
  6. long n = strtol(s, NULL, 10);
  7. printf("%ld\n", n);
  8. return 0;
  9. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
compilation info
prog.c: In function ‘main’:
prog.c:5:9: error: expected identifier or ‘(’ before ‘[’ token
prog.c:6:5: warning: implicit declaration of function ‘strtol’ [-Wimplicit-function-declaration]
prog.c:6:21: error: ‘s’ undeclared (first use in this function)
prog.c:6:21: note: each undeclared identifier is reported only once for each function it appears in
stdout
Standard output is empty