| 4.4 Flow of Control |
if( expression ) statement
if( expression ) statement else statement
for( expression;
expression; expression)
statement
while( expression ) statement
do statement while( expression )
break, continue, next, & redo
switch -- case
Write a program in assembly language that:
for statement construct.
INC, ADD, CMP, and Jcc to approximate
both if statements and a do statement. The sequence starts like
this 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377, 610, 987
Turn in a printed error free listing and the output of your program. Include a copy of any testing that you did to verify the program was correct. For this lab, use a spreadsheet to help your testing.
Instructor: Louis Taber, louis.taber.at.pima at gmail dot com (520) 206-6850
My web site in Cleveland, OH
The Pima Community College web site
| 4.4 Flow of Control |