A series of steps for accomplishing a set goal.
A recursive function which calls itself twice during the course of its
How much time and space does an algorithm require to run.
A mathematical function where f(n) = n * f(n-1), f(0) = 1.
The condition in a recursion function
How an algorithm is actually done, programmed, coded, etc. For any
algorithm, there are many ways to actually code it up, to implement it.
A programming construct where looping is used to complete an action
multiple times. The for() and while() constructs are prime
examples of iterative constructs.
Recursion where only one call is made to the function from within the
function (thus if we were to draw out the recursive calls, we would see
a straight, or linear, path).
Recursion where more than one call is made to the function from within
itself. This leads to exponential growth in the number of recursive
In terms a recursion, circularity refers to a recursive function being called
with the same arguments as a previous call, leading to an endless cycle of
Space in the computer where information is stored.
A set of functions which call themselves recursively indirectly by calling
each other. For example, one might have a set of two functions,
is_even() and is_odd(), each defined in terms of the other.
A recursive function where the argument passed to the function is the
A definition defined in terms of itself, either directly (explicitly using
itself) or indirectly (using a function which then calls itself either
directly or indirectly).
A method of programming whereby a function directly or indirectly calls
itself. Recursion is often presented as an alternative to iteration.
Memory, disk space, CPU time, etc. Aspects of the system that only come
in limited quantities. Use of resources by one application reduces the
amount of these resources available to other applications (if there are
three oranges on the table and I take one, that leaves only two of the
three for you).
A recursive procedure where the recursive call is the last action to be
taken by the function. Tail recursive functions are generally easy to
transform into iterative functions.
The condition upon which a recursive solution stops recurring. This
terminating condition, known as the base case, is the problem in a
recursive that we know how to solve explicitly, the "small" problem to
which we know the answer.
Towers of Hanoi
A puzzle developed in 1883 by Edouard Lucas. Three poles upon which a
certain number of round discs, increasing in size, are placed (all of the
discs initially start on the first pole). The object of the puzzle is to
move all of the discs from one pole to another pole. Only one disc can
be removed from the poles at any one time, and no disc can be placed upon
a larger disc.