Skip to content

Instantly share code, notes, and snippets.

@BolajiOlajide
Last active April 6, 2017 06:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BolajiOlajide/cb2eb9a3f8770cf347689e91d1bfc68b to your computer and use it in GitHub Desktop.
Save BolajiOlajide/cb2eb9a3f8770cf347689e91d1bfc68b to your computer and use it in GitHub Desktop.
Python Recursive Function 1
def power(a,b):
if b == 0:
return 1
elif a == 0:
return 0
else:
return a * power(a,b-1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment