+ 2
How to create a menu in C program using do/while loops?
A menu for Decimal to Binary and Octal form and loops!
1 Resposta
+ 2
do{
printf("Menu: ");
printdf("\n1. Decimal to binary");
printf("\n2. Decimal to octal");
printf("\nEnter your choice (1 or 2): ");
scanf("%d",&ch);
/* Code here*/
printf ("\nWant to continue (y/n): ");
scanf ("%c",&ch1);
}while(ch1=='y' || ch1=='Y');