Advertisement
Guest User

Untitled

a guest
Jun 20th, 2019
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. print("num1")
  2. num1=int(input())
  3. print("num2")
  4. num2=int(input())
  5. print("enter your operator +,-,/,*")
  6. num3=(input())
  7. if num1==56 and num2==3 and num3=="*":
  8. print("555")
  9. elif num1==45 and num2==6 and num3=="+":
  10. print("77")
  11.  
  12. elif num3=="+":
  13. plus=num1+num2
  14. print(plus)
  15.  
  16.  
  17. elif num3 == "*":
  18. mul = num1 * num2
  19. print(mul)
  20.  
  21.  
  22. elif num3 == "/":
  23. div= num1 / num2
  24.  
  25. print(div)
  26.  
  27.  
  28. elif num3 == "-":
  29. sub = num1 - num2
  30. print(sub)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement