//Program to make Simple Arithmetic Calculator
#include<stdio.h>
#include<conio.h>
int main()
{
int a,b;
clrscr();
printf("Enter the Integers to Calculate the Sum, Difference, Product \nand Division between them\n");
scanf("%d%d",&a,&b);
printf("\nThe sum = %d",a+b);
printf("\nThe Difference = %d",a-b);
printf("\nThe Product = %d",a*b);
printf("\nThe Division = %d",a/b);
getch();
return 0;
}
To Run this Program Copy it in text editor and save as .c
Then double click on it and then it will get opened in your compiler.
Click on run.
#include<stdio.h>
#include<conio.h>
int main()
{
int a,b;
clrscr();
printf("Enter the Integers to Calculate the Sum, Difference, Product \nand Division between them\n");
scanf("%d%d",&a,&b);
printf("\nThe sum = %d",a+b);
printf("\nThe Difference = %d",a-b);
printf("\nThe Product = %d",a*b);
printf("\nThe Division = %d",a/b);
getch();
return 0;
}
To Run this Program Copy it in text editor and save as .c
Then double click on it and then it will get opened in your compiler.
Click on run.
Calculator program in C
ReplyDeleteIn C language we can design a program to add, subtract, multiply, divide any number, these all operation you can perform by using switch case.