Programming loops on C++ Language was divided into three methods (for, while, do while). syntax "for" used to automatic looping and more often used instead "while" and "do while". When the syntax of "while" and "do while" is can be called Looping Conditional so, "while" and "do while" more flexible. But also depends on the programmer who want to use it.
Now, I will explain the prototype and simple example script of C++ Programming loops (for, while, do while).
First, below is the prototype of Programming Loop using Syntax "for".
for (initialization; condition; increase/decrease){Second, below is the prototype of Programming Loop using Syntax "while".
statements;
}
while(condition){Third, below is the prototype of Programming Loop using Syntax "do while".
statements;
}
do{For the examples of the script, you can clicking here.
statements;
}while(condition);
references :
http://www.cplusplus.com
http://www.tutorialspoint.com
Paper 4Share - C++ Programming loops (for, while, do while) [Part 1]