Computers for children

From: Uncle Roger <sinasohn_at_ricochet.net>
Date: Wed Jan 13 19:05:55 1999

At 07:01 PM 1/12/99 -0500, you wrote:
>In fact, as I understand, all that FOR...NEXT and so on are are low-level
>implementations of common usages of GOTO.

High-level -- just as all BASIC/COBOL/C/Etc commands are high-level
representations of many more assembly language commands.

For-next:

Start-Value = 1
End-Value = 99
Increment = 1
Counter = Start-Value
:Start-For
If Counter > End-Value Then
   Goto End-For
end-if
do stuff
Counter = Counter + Increment
Goto Start-For
:End-For

In fact there could be times when you would want to do this this way
instead of using a for-next -- as in if you want you increment to change
each time, or if you want to repeat a single iteration until some other
condition is met.


--------------------------------------------------------------------- O-

Uncle Roger "There is pleasure pure in being mad
roger_at_sinasohn.com that none but madmen know."
Roger Louis Sinasohn & Associates
San Francisco, California http://www.sinasohn.com/
Received on Wed Jan 13 1999 - 19:05:55 GMT

This archive was generated by hypermail 2.3.0 : Fri Oct 10 2014 - 23:32:06 BST