mirror of
https://github.com/onyx-and-iris/grokking-algorithms.git
synced 2024-09-27 19:17:04 +01:00
11 lines
270 B
Markdown
11 lines
270 B
Markdown
|
# Recursion
|
||
|
|
||
|
Recursive functions must have both:
|
||
|
|
||
|
- one or more base cases
|
||
|
- a recursive case
|
||
|
|
||
|
The base cases are required to ensure the recursion stops when meeting a condition
|
||
|
|
||
|
The recursive case adds functions onto the call stack and completes each one top down.
|