January 2002
Beginner
576 pages
13h 23m
English
A loop is a repetitive programming construct that allows a statement or a series of statements to process over and over again until a condition is met. Consequently, loops provide an excellent way to cycle through code. If you are examining a string, you can cycle through one character or word at a time. If you are incrementing a number, each loop can add another value to your number. If you are looking for an object in a collection of objects, the loop is the perfect vehicle to enumerate (list) your objects.
The Do..Loop statement executes code inside the Do..Loop either while a condition remains true or until a condition becomes true, depending on how the statement is constructed. There are two ways to use ...