Showing posts with label C - Switch Statement. Show all posts
Showing posts with label C - Switch Statement. Show all posts

Simple Calculator Using Switch Statement

#include "stdio.h"
#include "conio.h"
int main (void)
{
    int a,x,y;
    printf("Please enter 1 or 2 or 3 or 4 for addition, subtraction,multplication and division respectively:");
    scanf("%d", &a);
    switch(a)