The definition of the word Recursion is “(mathematics) an expression such that each term is generated by repeating a particular mathematical operation”. Recursion is one of the most powerful “tools” in a functional programming language.
Recursion can be used to divide techniques to problem solving, where a problem is broken to smaller subproblems, the subproblems are solved, and the results are “merged” to generate the final result.
Recursion happens when a function calls itself directly or indirectly. Recursion is used instead of the conventional loop statements of other programming languages, such as while and for in C.