*C program* to perform *basic arithmetic operations* which are addition, subtraction, multiplication, and division of two numbers.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
#include<stdio.h> #include<conio.h> void main() { int a=10,b=3,c,r; float d; clrscr(); printf("The value of A is %d",a); printf("\nThe value of B is %d",b); c=a+b; printf("\nSum is %d\n",c); c=a-b; printf("Subtration is %d\n",c); printf("Multipliction is %d",a*b); d=a/b; printf("\nDivision is %.4f",d); r=a%b; printf("\nRemaindr is %d",r); getch(); } O/P:The value of A is 10 The value of B is 3 Sum is 13 Subtraction is 7 Multiplication is 30 Division is 3.3333 Remainder is 1 |

(Visited 22 times, 1 visits today)