A little test project for B.Y.O.P
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
391 B

  1. #!/usr/bin/python3
  2. def add(x, y):
  3. return x + y
  4. def main():
  5. x = int(input("Input x: "))
  6. y = int(input("Input y: "))
  7. # returns x + y
  8. addition = add(x, y)
  9. print(addition)
  10. # sub(x, y) returns x - y
  11. # mult(x, y) returns x * y
  12. # div(x, y) returns x // y
  13. # mod(x, y) returns x % y
  14. # expo(x, y) returns x ** y
  15. if __name__ == "__main__":
  16. main()