Part of my current assignment requires reading input from a file (Using I/O redirection) into a string of char, then parsing it, converting the numbers to int and saving that to an array of int. However, I can't get atoi to work for it-I'm using a wrong argument for it, but I don't know exactly how to fix it.
Here's the segment in question:
I can provide the whole program if you need that as well. What's wrong with my argument?Code:i = atoi(input[cnt2]);