Skip to content

Instantly share code, notes, and snippets.

@t0phr
Created November 24, 2015 19:46
Show Gist options
  • Save t0phr/fdb0f222e628c77f9e8c to your computer and use it in GitHub Desktop.
Save t0phr/fdb0f222e628c77f9e8c to your computer and use it in GitHub Desktop.
def f(m, n):
global calls
calls += 1
if m == 0:
return n + 1
elif n == 0:
return f(m - 1, 1)
else:
return f(m - 1, f(m, n - 1))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment