CODE
#include <stdio.h>
#include <conio.h>
#include <process.h>
void main ()
{
int a, b, c, choice;
clrscr ();
printf ("\t\t\t\t ** Calculation Program ** ");
printf ("\n\n\n\nEnter First Value: ");
scanf ("%d", &a);
printf ("\n\nEnter Second Value: ");
scanf ("%d", &b);
printf ("\n\n\t1. Addition");
printf ("\n\n\t2. Subtraction");
printf ("\n\n\t3. Multiplication");
printf ("\n\n\t4. Divide");
printf("\n\n\t5. Exit");
printf ("\n\n\nSelect Your Choice: ");
scanf ("%d", &choice);
switch (choice)
{
case 1:
c = a + b;
break;
case 2:
c = a - b;
break;
case 3:
c = a * b;
break;
case 4:
c = (float)a / b;
break;
case 5:
printf ("\n\nThank Your For Using This Program");
getch ();
exit (0);
}
if(choice>=6)
{
printf("\n\nInvalid Key!!!");
printf("\n\n\nTry Again Later.");
getch ();
exit (0);
}
printf ("\n\nResult = %d", c);
printf ("\n\n\nThank You!!!!!");
getch ();
}
mod edit: added code tags: