- To understand recursion, you must first understand .
- In a stack data structure, you can only add and remove from the of the stack.
- The term for adding to a stack is , while removing from a stack is .
- Python lists can be used as a stack, with the method for pushing and method for popping.
- Function calls make use of a stack called the .
- The call stack pushes when functions are called and pops them when functions return.
- Frame objects contain the and for a function call.
- The sys.setrecursionlimit() function can change the maximum recursion depth. The times that it’s appropriate to call this is .
- Recursive functions must always have base case and recursive case.
- "Iterative" means the code uses a .
- Unlike recursive algorithms, iterative algorithms will never .
- Recursion and iteration are equally powerful. There is nothing recursion can do that you can't do with a and a .
- The recursive factorial solution can be confusing because code is run and the recursive call.
- The recursive factorial solution isn’t used in real world code because calculating large factorials results in a .
- The recursive Fibonacci solution isn’t used in real world code because calculating large Fibonacci numbers requires .
- Recursion is a good technique to use when the problem involves and .