Modified Chapter 7 Presentation
Modified Chapter 7 Presentation
Seventh Edition
Chapter 7:
The Repetition Structure
Objectives
Figure 7-5 Problem specification and IPO chart for the Wheels & More program
An Introduction to Programming with C++, Seventh Edition 11
Using a Pretest Loop to Solve a Real-
World Problem (cont’d.)
• The flowlines leading out are marked “T” (true) and “F”
(false)
• The “T” line points to the loop body
• The “F” line points to the instructions to be processed if
the loop’s condition evaluates to false
• The flowline entering the diamond and symbols and
flowlines of the true path form a circle, or loop
• This distinguishes a repetition structure from a
selection structure in a flowchart
Figure 7-25 Problem specification for the Jasper Music Company program