<1> Conditional. A single selection
structure is the choice of two
actions based on some conditional.
The conditional is presented in a
diamond-shaped box. In general,
the conditional poses a question
that requires a decision. If the
decision is yes, <2> is executed. If
the decision is no, <3> is executed.
<2> Yes Sequence. This is the action
that is executed when a yes
decision results from the
<3> No Sequence. This is the action
<3> No Sequence
that is executed when a no decision
results from the condition.
Simple Selection Structure
Case Structure. The case selection structure, shown in
Figure A-6, asks a question in the form of a conditional that
allows a choice from multiple actions. A specific action is
taken for each response.
Iteration Structure. Iteration is used to execute a
group of structures repeatedly while a condition is true. This
handbook uses two types of iteration structures: do while and
for. The two structures are described in the following
Do While Structure. The do while structure, shown in
Figure A-7, asks a question in the form of a conditional and
executes a group of structures while the conditional is true.
For Structure. The for structure, shown in Figure A-8,
executes a group of structures for a set number of iterations.
Execution stops when the set number of iterations is completed.