So I have no idea how to make atoi() work in my program right about now. I have a function written that does exactly what I want atoi() to do, but the professor insists on the use of atoi() instead of our own functions.
The output is always 0. I know it means that the input string cannot be converted, but I had this issue even when I just wrote something like atoi("jdghlgjsdh"). I have not included the code for the function len.
int len(char *a);
int main(int argc, char *argv)
int atoi(const char *nptr);
printf("Output of strlen: %d \n",argv);
for(i = 1; i < argc; i++)
/* printf("Output of strlen: %d \n",len(argv[i]));*/