I am working my way through the tutorials on this site and have a question pertaining to this example:
#include <iostream>
using namespace std;
int main ()
{
int n;
cout << "Enter the starting number > ";
cin >> n;
while (n>0) {
cout << n << ", ";
--n;
}
cout << "FIRE!\n";
return 0;
}
my question has to do with the line reading: cout << n << ", ",;
I'm not sure what the ( ", ",;) means.
can anyone lend an answer real quick?
thank you in advance for your help
John
That just prints a string containing a comma and a space after the number. For example if n = 5, it would print output: "5, ". When n is decremented it will do the same for 4.