How many times is a do while loop guaranteed to loop?
Answers
Answered by
5
Hi,
Do while will execute atleast one time.. and it is guaranteed.
This happens because we execute code block first and then check condition. in do while loop.
Do while will execute atleast one time.. and it is guaranteed.
This happens because we execute code block first and then check condition. in do while loop.
Answered by
2
Answer:
Do while loop will execute at least one time.
Explanation:
Syntax of a DO while loop:
do
{
body of a loop;
}
while ( condition )
Do while loop is known as Exit controlled loop. Even if the condition is not true for the first time then control will also enter in loop. The do while loop can be used when number of iteration not exactly known.
Similar questions