repeat loop

Computing Dictionary

repeat loop definition

programming
(Or "do loop") A loop construct found in many procedural languages which repeatedly executes some instructions while a condition is true.
Repeat loops are found in Perl, Pascal, BASIC and C. The initial keyword may be "repeat" or "do" and the condition may be introduced with a "while" or "until" keyword.
In constrast to a while loop, the "loop body" is executed once before the condition is tested. This is useful when the condition depends on the action of the loop body. In the following BASIC loop "Hello" is printed once despite the fact that the condition is false;
i = 2 repeat print "Hello" i = i+1 until i>0
See also while loop and for loop.
(1999-05-06)
The Free On-line Dictionary of Computing, © Denis Howe 2010 http://foldoc.org
Cite This Source
Explore Dictionary.com
Previous Definition: repeat
Next Definition: repeat oneself
Words Near: repeat loop
More from Thesaurus.com
Synonyms and Antonyms for repeat loop
More from Reference.com
Search for articles containing repeat loop
More from Dictionary.com Translator
Dictionary.com Word FAQs

Dictionary.com presents 366 FAQs, incorporating some of the frequently asked questions from the past with newer queries.

Copyright © 2014 Dictionary.com, LLC. All rights reserved.
  • Please Login or Sign Up to use the Recent Searches feature
FAVORITES
RECENT

;