Program to do Arithmetic Operation

The arithmetic operation are used to perform arithmetic operation includes operators like Addition, Subtraction, Multiplication and Division.

How to

Take two variables a and b. The vaule of a is 6 and b is 3.

Addition a+b = 9
Subtraction a-b = 3
Multiplication a*b = 18
Division a/b = 2

Program
a = input("Enter first number:")
b = input("Enter second number:")

sum = float(a) + float(b)
min = float(a) - float(b)
mlt = float(a) * float(b)
div = float(a) / float(b)

print(sum)
print(min)
print(mlt)
Print(div)

Output
Enter fist number 6
Enter second number 3

Leave a Reply