Error in loop

closed account (E0p9LyTq)
Look closely at line 12.

A for loop uses ; (semicolons), not , (commas)

http://www.cplusplus.com/doc/tutorial/control/
1
2
3
4
5
6
7
8
9
#include <iostream>
using namespace std;

int main(int argc, char* argv[])
{
for (int i = 0; i < 10; i++)
	{cout << i << endl;}
return 0;
}
Topic archived. No new replies allowed.