this is my first post here. i started learning software engineering this month and i'm tring to code a software using c. i cant found the mistake to change it .. can anyone help me please!
#include <stdio.h>
void main()
{
int a,b,e;
char operation;
printf ("enter the first number:");
scanf ("%d",&a);
printf ("enter the second number:");
scanf ("%d",&b);
printf ("enter the operation:");
scanf ("%c", &operation);
switch (operation)
{ case '+' : e=a+b;
break;
case '-' : e=a-b;
break;
case '*' : e=a*b;
break;
case '/' : e=a/b;
break;
default: printf("wrong choice!!");
}
printf("%d %c %d = %d \n", a, operation, b, e);
}