Turing's Craft exercise stumped me... seems too easy.
- by Chris
"Write a for loop that prints the integers 1 through 40, separated by spaces or new lines. You may use only one variable, count which has already been declared as an integer."
So I use...
for(count = 1; count <= 40; count++)
{
cout << " " << count;
}
but they are using stdio.h as the only header and cout is not recognized. It hints that the output format should be (" ",count), but I can't figure out what print function to use. stdio.h can use fprintf or fwrite, but I don't have enough parameters for either function. Any ideas?