Table of Contents18 Counter-Controlled Repetitionwith a while Loop The for Repetition Structurea.k.a. the for loop When Does the for Loop Initialize, Test and Modify ? A for Loop That Counts to 10 We can count backwards We can count by twos ... or 7’s, or whatever ... The do while Repetitive Structure Example of a do while Loop The while Loop that Tested User Input Personal Preference The char Data Type Example The getchar ( ) function Example using getchar The switch Multiple-Selection Structure |
Author: Sue Bogar
Email: burt@umbc Home Page: www.cs.umbc.edu/~burt |