in while loop : first check the expression and if its true then run the loop but
int do while loop : first run the loop then check the expression so in the do while loop At least run the one loop ( sorry for my eng language :D )
note in all of the loop statement run the loop until the expression is true !!!!
you can do some fun with your cpp compiler :D
check it
1 2 3 4 5 6 7 8 9 10 11 12 13
#define repeat do
#define until( exp ) while ( !(exp) )
void main()
{
int i = 0;
repeat
{
cout << "hello" << endl;
i++;
}
until ( i == 10 );
}