The selection construct is used to create a branch in a program. The computer selects which branch to follow based on the outcome of a condition, using an IF…TH
15
What are loops?
Loops are used to make a computer repeat a set of instructions more than once.
15
What are the types of loops?
definite and indefinite
15
When do you use a definite loop?
A definite loop is used when you know in advance how often the instructions in the body of the loop are to be repeated
15
When do you use a indefinite loop?
An indefinite loop is used when the number of times a loop will need to be repeated is not known in advance
15
When do you use a definite iteration?
This is used when the number of iterations, or turns of the loop, is known in advance