Every time i try to compile this c program i get this error: cannot convert ‘double*’ to ‘const char*’ for argument ‘1’ to ‘int atoi(const char*)’ and when i try online gdb it works perfectly fine.Here is the code can anyone point out me to my mistake why this code not compiling on my side?
int main(int argc,char *argv)
a = atoi(&s.d) - atoi(&s.c);
printf("Size of char: %d\n",sizeof(s.c));
printf("Size of double: %d\n",sizeof(s.d));
printf("Size of struct: %d\n",sizeof(s));