//this is a program to print even numbers from 1-10 using do while loop
#include<stdio.h>
#include<conio.h>
void main()
{
int i=1;
printf("\n\nPrinting even numbers form 1-10\n");
do{
if(i%2==0)
{
printf(" %d ",i);
}
i++;
}while(i<10);
getch();
}
#include<stdio.h>
#include<conio.h>
void main()
{
int i=1;
printf("\n\nPrinting even numbers form 1-10\n");
do{
if(i%2==0)
{
printf(" %d ",i);
}
i++;
}while(i<10);
getch();
}