Skip to content

Instantly share code, notes, and snippets.

@kelvinndmo
Created December 28, 2019 17:08
Show Gist options
  • Save kelvinndmo/31d113fb5813f745c297f6ef03c4aacf to your computer and use it in GitHub Desktop.
Save kelvinndmo/31d113fb5813f745c297f6ef03c4aacf to your computer and use it in GitHub Desktop.
def add(x, y):
return x + y
def substract(x, y):
return x - y
def multiply(x, y):
return x * y
def divide(x, y):
if y == 0:
raise ValueError("cannot divide a number by zero")
return x/y
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment