Best Answer

Do statement : Here the do loop exicutes once without cheching the condition and then the condition will be checked if condition becomes true then again loop begins from do and then exictes here if you are given value is n then loop exictues n+1 times.

for statement : Here the for loop will be initilized first and the condition will be checked if the condition then the pointer enters the loop else not.And after completion of the loop the pointer again moves to the for statement and the increment/Decrement will be done as you provided in loop then the condition will be checked if satisfy then it enteres loop else not

User Avatar

Wiki User

โˆ™ 2012-02-01 19:09:59
This answer is:
User Avatar
Study guides
See all Study Guides
Create a Study Guide
11 Reviews

Add your answer:

Earn +20 pts
Q: Do statement and For statement comparisons?
Write your answer...
Still have questions?
magnify glass
People also asked