Recursion is a method of solving a problem, where the solution is based on “smaller” solutions of the same problem. In most programming languages (including Java) this is achieved by a function that calls itself in its definition. As a recursive joke says, “In order to understand recursion, you must firstly understand recursion”. There are […]