Recursion
The process in which a function calls itself directly or indirectly with a failure condition is called recursion.
Properties of Recursion:
Performing the same operations multiple times with different inputs.
In every step, we try smaller inputs to make the problem smaller.
Base condition is needed to stop the recursion otherwise infinite loop will occur.
How are recursive functions stored in memory?
Recursion uses more memory, because the recursive function adds to the stack with each recursive call,
and keeps the values there until the call is finished. The recursive function uses LIFO structure.