Browse Definitions:
Definition

recursion

Contributor(s): Lee Savidge

In computer programming, a recursion (noun, pronounced ree-KUHR-zhion) is programming that is recursive (adjective), and recursive has two related meanings:

1) A recursive procedure or routine is one that has the ability to call itself. This usually means that it has the capability to save the condition it was in or the particular process it is serving when it calls itself (otherwise, any variable values that have been developed in executing the code are overlaid by the next iteration or go-through). Typically, this is done by saving values in registers or data area stacks before calling itself or at the beginning of the sequence where it has just been reentered.

2) A recursive expression is a function, algorithm, or sequence of instructions (typically, an IF, THEN, ELSE sequence) that loops back to the beginning of itself until it detects that some condition has been satisfied. Here is a simple example (using a made-up computer source language):

 

CODELINE1   N=0;      
CODELINE2   IF N=<10 THEN DO WRITE LETTER;   
CODELINE3   ELSE GOTO CODELINE6;
CODELINE4   N=N+1;
CODELINE5   GOTO CODELINE2;
CODELINE6   ...some other instruction

Here, the instructions labeled CODELINE2 through CODELINE5 are recursive until the condition of N having the value of 10. "IF N=<10" means "If N has a value less than 10." "N=N+1" means "Add 1 to the current value of N."

In mathematics, recursion has similar but more complicated meanings than it does when used in programming.

This was last updated in August 2005

Start the conversation

Send me notifications when other members comment.

By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Please create a username to comment.

-ADS BY GOOGLE

File Extensions and File Formats

Powered by:

SearchCompliance

  • pure risk (absolute risk)

    Pure risk, also called absolute risk, is a category of threat that is beyond human control and has only one possible outcome if ...

  • risk assessment

    Risk assessment is the identification of hazards that could negatively impact an organization's ability to conduct business.

  • audit program (audit plan)

    An audit program, also called an audit plan, is an action plan that documents what procedures an auditor will follow to validate ...

SearchSecurity

SearchHealthIT

SearchDisasterRecovery

  • business continuity and disaster recovery (BCDR)

    Business continuity and disaster recovery (BCDR) are closely related practices that describe an organization's preparation for ...

  • business continuity plan (BCP)

    A business continuity plan (BCP) is a document that consists of the critical information an organization needs to continue ...

  • call tree

    A call tree -- sometimes referred to as a phone tree -- is a telecommunications chain for notifying specific individuals of an ...

SearchStorage

  • nearline storage

    Nearline storage is the on-site storage of data on removable media.

  • application-aware storage

    Application-aware storage is a storage system with built-in intelligence about relevant applications and their utilization ...

  • Remote Direct Memory Access (RDMA)

    Remote Direct Memory Access (RDMA) is a technology that allows computers in a network to exchange data in main memory without ...

SearchSolidStateStorage

  • 3D XPoint

    3D XPoint is memory storage technology jointly developed by Intel and Micron Technology Inc.

  • RRAM or ReRAM (resistive RAM)

    RRAM or ReRAM (resistive random access memory) is a form of nonvolatile storage that operates by changing the resistance of a ...

  • JEDEC

    JEDEC is a global industry group that develops open standards for microelectronics.

SearchCloudStorage

  • Google Cloud Storage

    Google Cloud Storage is an enterprise public cloud storage platform that can house large unstructured data sets.

  • RESTful API

    A RESTful application program interface breaks down a transaction to create a series of small modules, each of which addresses an...

  • cloud storage infrastructure

    Cloud storage infrastructure is the hardware and software framework that supports the computing requirements of a private or ...

Close