SHARE
TWEET

Untitled

a guest Dec 15th, 2019 70 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. num1 = int(input("Type a number"))
  3. num2 = int(input("And another"))
  4.  
  5. op = input("What operation? >")
  6.  
  7. if op == "+":
  8.     ans = num1 + num2
  9. elif op == "-":
  10.     ans = num1 - num2
  11. elif op =="/":
  12.     ans = num1 / num2
  13. else:
  14.     ans = num1 * num2
  15. print(ans)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top