FIT100
Anatomy of for
The for-statement syntax
for ( <initialize>; <continue test>; <next iteration> ) {
• <statement list>
*}
*
•<initialize> -- gives iteration variable its first value
•<continue test> -- this test is performed before starting each cycle of loop; if false, quit
•<next iteration> -- the change to the iteration variable after each cycle
for’s 3 control specifications -- the “control trio”-- are connected by an iteration variable