Control Flow: Loops
Loops can execute a block of code as long as a specified condition is reached.
- for loop: When you know exactly how many times you want to loop.
- while loop: Loops through a block of code as long as a specified condition is true.
- do...while loop: Executes the block once, then repeats as long as the condition is true.
No reviews yet.