Four-Processor Calculator

in #python6 years ago

print "+ ---> collection"
print "- ---> sticker"
print "* ---> impact"
print "/ ---> chamber"

while (True):
op = raw_input ("choose action:")
if (op == "+"):
op1=input("enter first number:")
op2=input("enter second count:")
print op1+op2
elif (op == "-"):
op1=input("enter first number:")
op2=input("enter second count:")
print op1-op2
elif (op == ""):
op1=input("enter first number:")
op2=input("enter second number:")
print op1
op2
elif (op == "/"):
op1=input("enter first number:")
op2=input("enter second number:")
if (op2== 0):
print "A number can not be divided by 0."
else:
print"op1/op2"
else:
print "indeterminate operation!"

Coin Marketplace

STEEM 0.26
TRX 0.20
JST 0.038
BTC 92922.43
ETH 3362.42
USDT 1.00
SBD 3.72