\n <\/a>\n <\/p>\n Use of loops with \u201cwhile\u201d while(condition) When the condition becomes false, program control passes to the line immediately following the loop.<\/p>\n Here, key point of the while loop is that the loop might not ever run. When the condition is tested and the result is false, the loop body will be skipped and the first statement after the while loop will be executed.<\/p>\n link: http:\/ \n <\/a>\n <\/p>\n Use of loops with “while” while(condition) When the condition becomes false, program control passes to the line immediately following the loop.<\/p>\n Here, key point of the while loop is that the loop might not ever run. When the condition is tested and the result is false, the loop body will be skipped and the first statement after the while loop will be executed.<\/p>\n link: http:\/\/www.tutorialspoint.com\/cplusplus\/cpp_while_loop.htm<\/a>
Syntax:
The syntax of a while loop in C++ is:<\/p>\n
{
statement(s);
}
Here, statement(s) may be a single statement or a block of statements.
The condition may be any expression, and true is any non-zero value. The loop iterates while the condition is true.<\/p>\n
#TC1017<\/a> #Mastery19<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"mastery 19<\/a><\/h2>\n
Syntax:
The syntax of a while loop in C++ is:<\/p>\n
{
statement(s);
}
Here, statement(s) may be a single statement or a block of statements.
The condition may be any expression, and true is any non-zero value. The loop iterates while the condition is true.<\/p>\n
#TC1017<\/a> #Mastery19<\/a><\/p>\n