prog.c:9:18: warning: implicitly declaring library function 'abs' with type 'int (int)' [-Wimplicit-function-declaration]
int tempnum = abs(num);
^
prog.c:9:18: note: include the header <stdlib.h> or explicitly provide a declaration for 'abs'
prog.c:25:26: error: expected expression
printf("%s%s", (num<0?)"-":"", res + lastpos + 1); /* print starting from the last digit added */
^
prog.c:25:26: error: expected ':'
printf("%s%s", (num<0?)"-":"", res + lastpos + 1); /* print starting from the last digit added */
^
:
prog.c:25:25: note: to match this '?'
printf("%s%s", (num<0?)"-":"", res + lastpos + 1); /* print starting from the last digit added */
^
prog.c:25:26: error: expected expression
printf("%s%s", (num<0?)"-":"", res + lastpos + 1); /* print starting from the last digit added */
^
1 warning and 3 errors generated.