+ 2
So what is the difference between do and do...while loops?
2 Respuestas
+ 14
do while() , while ()
/*in do while() , condition is checked after executing the statements , while in while () loop , condition is checked before execution of the statement(s)*/
+ 8
do while in an exit control loop. while is an entry control loop. The difference is in when the condition gets evaluated. ... Do while loopwill be executed atleast once.......but while loop will check the condition first and then it may or may not get executed depending on the condition.
https://stackoverflow.com/questions/3625759/difference-between-while-loop-and-do-while-loop