MCPcopy Create free account
hub / github.com/geekcomputers/Python / step

Function step

fibonacci.py:29–34  ·  view source on GitHub ↗
(n: int)

Source from the content-addressed store, hash-verified

27 b = 1
28
29 def step(n: int) -> int:
30 nonlocal a, b
31 if n <= 0:
32 return a
33 a, b = b, a + b
34 return step(n - 1)
35
36 return step(n)
37

Callers 1

getFibonacciRecursiveFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected