#include<stdio.h>
#include<conio.h>
void main()
{
int num;
char ch;
clrscr();
do{
printf("Enter a number");
scanf("%d",&num);
printf("\n\n");
printf("You entered %d",num);
printf("Press 'y' to restart again?");
ch=getche();
}
while(ch=='y');
getch();
}
If you have question, you can ask me freely!
#include<conio.h>
void main()
{
int num;
char ch;
clrscr();
do{
printf("Enter a number");
scanf("%d",&num);
printf("\n\n");
printf("You entered %d",num);
printf("Press 'y' to restart again?");
ch=getche();
}
while(ch=='y');
getch();
}
If you have question, you can ask me freely!
