So instead of going the ’ for’ route I decided to do it different using the while construction
This main code at the bottom works fine except that I get a warning on
saying it’s an implicit declaration of function ‘atoi’. Can anyone explain what I do wrong here?
MAIN CODE
int main(int argc, const char * argv[])
{
printf("Where should I start counting? ");
const char *i = readline(NULL);
int counter = atoi(i);
while (counter >= 0) {
printf("%d\n", counter);
if (counter%5 == 0) {
printf("Found one!, numer: %d\n", counter);
}
counter-=3;
}