-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add algol.ini, prime.si and prime examples
- Loading branch information
Showing
3 changed files
with
76 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
# algol.ini - use the algol compiler | ||
|
||
|
||
# load algol.bo from card reader using the sds universal loader | ||
dep bpt4 1 | ||
|
||
|
||
att cp card-punch | ||
att ptp zzz | ||
att lpt xxx | ||
|
||
#! /users/admin/sds/sds-kit/tools/mkdeck -a /users/admin/sds/sieve.si >source | ||
|
||
|
||
att cr /users/admin/sds/sds-kit/850645/pre.bo,/users/admin/sds/sds-kit/850648/850648-84,/users/admin/sds/sds-kit/850645/ldr.bo,/users/admin/sds/sds-kit/850816/algol.bo | ||
|
||
boot cr | ||
|
||
# Simulation stopped, P: 22713 (BRU 22712) | ||
|
||
# Compiler options | ||
# dep bpt1 1 down, use card reader | ||
# dep bpt2 1 down, use card punch | ||
# dep bpt3 1 down, type source | ||
# dep bpt4 0 down, call objty before codout | ||
|
||
# dep p 7347 no transfer address on algol.bo, start at 7347 | ||
|
||
# c | ||
|
||
#^E | ||
|
||
# Simulation stopped, P: 04534 (SKS 12006) waiting for CR | ||
# attach source code | ||
#att cr source | ||
|
||
#c | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
�ba@ I@@b@@ @@ d@a@I@ d@I@ a@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@� I@@@@@@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@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@�@@@@@@@@@@@@bI@ @b@@@bb@ @b@@ I@@@b bJ@@@b @@I@@b@@b@ @@@b @b@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@�@@@@@@@@@@@@b Q@J@ @b@@@b @b@@ Jb @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@�@@@@@@@@@@@@@@@@bI@ @b@@@bb@ @b@@ I@@@b bJ@@ @@@R@@ L@@@@b @b@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@�@@@@@@@@@@@@@@@@b Q@J@ @b@@ I@@@b bJ@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@�@@@@@@b @@I@@b@@ @J@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
'COMMENT' PRIME FACTORIZATION. | ||
INPUT = 7DIGITS,OUTPUT = FACTORS (ASCENDING ORDER); | ||
'BOOLEAN' 'PROCEDURE' PRIME (N); | ||
'VALUE' N;'INTEGER' N; | ||
'BEGIN' | ||
'EXTERNAL' NEXT; | ||
'INTEGER' Q; | ||
Q:= 2; | ||
PRIME1:'IF' Q*Q>N 'THEN' PRIME:='TRUE' | ||
'ELSE' 'IF' N\Q*Q = N | ||
'THEN' PRIME := 'FALSE' | ||
'ELSE 'BEGIN' NEXT (Q); 'GO TO' I PRIME 1 'END' | ||
'END' PRIME; | ||
|
||
'PROCEDURE' NEXT (X); | ||
'BEGIN' | ||
'BOOLEAN' 'EXTERNAL' PRIME; | ||
A:X := X + 1; | ||
'IF' 'NOT' PRIME (X) 'THEN' 'GO TO' A | ||
'END' NEXT; | ||
|
||
BEGIN:='BEGIN' | ||
'INTEGER' M, P, TYPEWRITER; | ||
'PROCEDURE' OUT (X); | ||
'BEGIN' OUTPUT (TYPEWRITER, 17); 10 (X); ENDIO 'END'; | ||
'EXTERNAL' NEXT; | ||
TYPEWRITER := 1; | ||
17:'FORMAT' "17"; | ||
INPUT (TYPEWRITER, 17); IO (M); ENDIO; | ||
P:= 2; | ||
PRIME3: 'IF' P*P>M | ||
'THEN' 'BEGIN' OUT (M); 'GO TO' BEGIN 'END' | ||
'ELSE' 'IF' M\P*P=M | ||
'THEN' 'BEGIN' OUT (P); M := M/P 'END' | ||
'ELSE' NEXT (P); | ||
'GO TO' PRIME3; | ||
'END' FACTORIZATION |