Here I am going to explain
how we can perform arithmetic operations in Python. I am going to show
addition, subtraction, multiplication & divide here.
Step
1: Open
IDLE(Python GUI) in your system.
Step 2 : Type the below code and save the code Eg:- I have saved with arithmetic.py
name.
a = input("Enter value: ")
b = input("Enter another value : ")
c = float(a) + float(b)
d = float(a) - float(b)
e = float(a) * float(b)
f = float(a) / float(b)
print("sum is ",c)
print("substraction is ",d)
print("multiplication is ",e)
print("division is ",f)
Step 3 : Open command prompt.
Step
4 : Go to the saved script folder.
Step
5 : Write python <Script name>.py for
execution.(Eg.- python arithmatic.py)


Image 1.