Answers for "python how to code a calculator"

0

Calculator in python

num1 = input("Enter a Number : ")
num2 = input("Enter a Number : ")
result = (num1 * num2)
print(result)
# And then print out the result
Posted by: Guest on August-21-2020
0

calculator in python

#Calculator in python
#No modules required
qus = input('')
if(qus=='ADDITON'):
  no1 = int(input())
  no2 = int(input())
  print(no1+no2)
  
if(qus=='MULTIPLICATION'):
  no1 = int(input())
  no2 = int(input())
  print(no1*no2)

if(qus=='DIVISION'):
  no1 = int(input())
  no2 = int(input())
  print(no1/no2)
  
if(qus=='SUBTRACTION'):
  no1 = int(input())
  no2 = int(input())
  print(no1-no2)
Posted by: Guest on October-04-2020

Python Answers by Framework

Browse Popular Code Answers by Language