Easier View

Very sorry, The posts are all mixed-up . View blog archieve to start learning =D

About Me

My name is Luke Chin. Here to teach you guys how to code C++

Thursday, April 12, 2007

The For Statement

//The for statement is much similar to the while statement loop wise

#include
using std::cout;
using std::cin;
using std::endl; // if you havent seen this before it justs ends the line

int main()
{

for (int A = 1 ; A<= 30 ; A++)
{
cout << A << endl;

}

system("pause");
return 0;
}

-the for statement is made up of 3 parts

for ("initalization" ; "condition" ; "action")

No comments: