A-M baby
This commit is contained in:
parent
764da6cbbb
commit
db842d013d
19005 changed files with 197040 additions and 7 deletions
|
|
@ -0,0 +1,22 @@
|
|||
# example from: http://www.xs4all.nl/~jmvdveer/algol.html - GPL #
|
||||
determine first generation;
|
||||
WHILE can represent next generation
|
||||
DO calculate next generation;
|
||||
print next generation
|
||||
OD.
|
||||
|
||||
determine first generation:
|
||||
INT previous := 1, current := 3.
|
||||
|
||||
can represent next generation:
|
||||
current <= max int - previous.
|
||||
|
||||
calculate next generation:
|
||||
INT new = current + previous;
|
||||
previous := current;
|
||||
current := new.
|
||||
|
||||
print next generation:
|
||||
printf (($lz","3z","3z","2z-d$, current,
|
||||
$xz","3z","3z","2z-d$, previous,
|
||||
$xd.n(real width - 1)d$, current / previous)).
|
||||
Loading…
Add table
Add a link
Reference in a new issue