The do while construct consists of a process symbol and a condition. First, the code within the block is executed, and then the condition is evaluated. If the condition is true the code within the block is executed again. This repeats until the condition becomes false. Because do while loops check the condition after the block is executed.
the do-while loop is an exit-condition loop. This means that the code must always be executed first and then the expression or test condition is evaluated.
do
{
statement;
}while(condition);
Example
#include
#include
void main()
{
int i=1;
clrscr();
do
{
printf("\n%d",i);
i++;
}while(i<=10);
getch();
}