-
Notifications
You must be signed in to change notification settings - Fork 9
/
quine.a68
40 lines (40 loc) · 1.14 KB
/
quine.a68
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
PROC s = (INT n)STRING:
( n|
"""", " ", ",", "|",
"PROC s = (INT n)STRING:",
"( n|",
");",
"main:",
"( FOR i FROM 5 TO 23 DO",
" print((s(i), new line));",
" IF i = 6 THEN",
" print((s(2), s(2), s(1), s(1), s(1), s(1), s(3), s(2),",
" s(1), s(2), s(1), s(3), s(2),",
" s(1), s(3), s(1), s(3), s(2),",
" s(1), s(4), s(1), s(3), new line));",
" FOR j FROM 5 TO 22 DO",
" print((s(2), s(2), s(1), s(j), s(1), s(3), new line))",
" OD;",
" print((s(2), s(2), s(1), s(23), s(1), s(4), new line));",
" print((s(2), s(2), s(1), s(24), s(1), new line))",
" FI",
" OD",
")"|
"Other"
);
main:
( FOR i FROM 5 TO 23 DO
print((s(i), new line));
IF i = 6 THEN
print((s(2), s(2), s(1), s(1), s(1), s(1), s(3), s(2),
s(1), s(2), s(1), s(3), s(2),
s(1), s(3), s(1), s(3), s(2),
s(1), s(4), s(1), s(3), new line));
FOR j FROM 5 TO 22 DO
print((s(2), s(2), s(1), s(j), s(1), s(3), new line))
OD;
print((s(2), s(2), s(1), s(23), s(1), s(4), new line));
print((s(2), s(2), s(1), s(24), s(1), new line))
FI
OD
)