
C H A P T E R 6
The Repetition Program
Structure
6.1 INTRODUCTION
This chapter presents the repetition program structure and using it for spec-
ifying, describing, and implementing algorithms in developing computatio nal
models. This structure and the corresponding statements a re discussed with
flowcharts, pseudo-code, and implementation in the Python programming lan-
guage. The repetition structure specifies that a block of statements be exe-
cuted repeatedly based on a given condition. Basically, the statements in the
process block of code are executed several times, so this structure is often
called a loop structure. A program segment that includes