From 9a5e6f24f2419cea2f7230635c6aa832569c651b Mon Sep 17 00:00:00 2001 From: "Eric S. Raymond" Date: Mon, 28 Jul 1997 20:10:08 -0400 Subject: [PATCH] Ready to upload. --- BUGS | 32 +- Makefile | 2 +- NEWS | 52 +- READ.ME | 8 +- doc/Makefile | 20 +- doc/READ.ME | 4 +- doc/intercal.mm | 1486 +++++++++++++++++------------- intercal.el | 11 +- intercal.lsm | 8 +- pit/CATALOG | 64 +- pit/Makefile | 35 +- pit/beer.doc | 368 ++++++++ pit/bubble.doc | 5 +- pit/change.doc | 31 + pit/change.i | 92 ++ pit/count.doc | 71 ++ pit/delta.fft | 258 ++++++ pit/fft.doc | 55 ++ pit/fft.i | 264 ++++++ pit/flonck.doc | 61 ++ pit/flonck.i | 277 ++++++ pit/hail_mary.doc | 56 ++ pit/hello.i | 16 + pit/iching.doc | 21 + pit/iching1.i | 19 + pit/iching2.i | 114 +++ pit/ins.doc | 132 +++ pit/ins.i | 475 ++++++++++ pit/lib/floatlib.doc | 249 +++++ pit/lib/floatlib.i | 1993 +++++++++++++++++++++++++++++++++++++++++ pit/lib/lib2.doc | 35 + pit/lib/lib2.i | 50 +- pit/lib/numio.doc | 98 +- pit/lib/numio.i | 98 +- pit/lib/syslib.3i | 323 +++++++ pit/lib/syslib.4i | 354 ++++++++ pit/lib/syslib.5i | 355 ++++++++ pit/lib/syslib.6i | 373 ++++++++ pit/lib/syslib.7i | 402 +++++++++ pit/lib/syslib.doc | 103 +++ pit/lib/syslib.i | 19 +- pit/lib/syslib3-7.doc | 53 ++ pit/life.doc | 5 +- pit/life2.i | 2 +- pit/pi.doc | 23 - pit/quine.i | 649 ++++++++++++++ pit/rot13.doc | 16 + pit/rot13.i | 256 +++--- pit/rot13b.doc | 117 +++ pit/rot13b.i | 74 ++ pit/tests/limits.3i | 2 +- pit/tests/testops.5i | 2 +- pit/tests/testsplat.i | 2 +- pit/tophat.fft | 258 ++++++ pit/yapp.doc | 26 + pit/yapp.i | 414 +++++++++ src/Makefile | 11 +- src/cesspool.c | 9 +- src/feh.c | 134 +-- src/ick.h | 23 +- src/ick.y | 2 +- src/lexer.l | 26 +- src/lose.h | 2 +- src/perpetrate.c | 84 +- src/sizes.h | 2 +- website/index.html | 19 +- 66 files changed, 9677 insertions(+), 1023 deletions(-) create mode 100644 pit/beer.doc create mode 100644 pit/change.doc create mode 100644 pit/change.i create mode 100644 pit/count.doc create mode 100644 pit/delta.fft create mode 100644 pit/fft.doc create mode 100644 pit/fft.i create mode 100644 pit/flonck.doc create mode 100644 pit/flonck.i create mode 100644 pit/hail_mary.doc create mode 100644 pit/hello.i create mode 100644 pit/iching.doc create mode 100644 pit/iching1.i create mode 100644 pit/iching2.i create mode 100644 pit/ins.doc create mode 100644 pit/ins.i create mode 100644 pit/lib/floatlib.doc create mode 100644 pit/lib/floatlib.i create mode 100644 pit/lib/lib2.doc create mode 100644 pit/lib/syslib.3i create mode 100644 pit/lib/syslib.4i create mode 100644 pit/lib/syslib.5i create mode 100644 pit/lib/syslib.6i create mode 100644 pit/lib/syslib.7i create mode 100644 pit/lib/syslib.doc create mode 100644 pit/lib/syslib3-7.doc create mode 100644 pit/quine.i create mode 100644 pit/rot13.doc create mode 100644 pit/rot13b.doc create mode 100644 pit/rot13b.i create mode 100644 pit/tophat.fft create mode 100644 pit/yapp.doc create mode 100644 pit/yapp.i diff --git a/BUGS b/BUGS index fc93014..a420d32 100644 --- a/BUGS +++ b/BUGS @@ -6,16 +6,12 @@ TO DO agenda items through the current release. ESR = Eric S. Raymond SS = Steve Swales -LLH = Louis Howell -BR = Brian Raiter +LHH = Louis Howell +BLR = Brian Raiter 1) (ESR) INTERCAL would be intrinsically a crock even if it worked right. -2) (SS) The system library syslib.i does not appear to work 100% as advertised. - (ESR) Louis has corrected several bugs. The gods alone know what others - are lurking in there... - -3) (LLH) The lexical analyzer is not completely independent of newlines. +2) (LHH) The lexical analyzer is not completely independent of newlines. There is a conflict between the fact that newlines should be ignored almost everywhere, and the facts that the error mechanism wants to know about line numbers and the splat mechanism wants @@ -41,7 +37,7 @@ BR = Brian Raiter relatively small gain, and anyone trying it should make sure the result isn't buggier than the current version. -4) (BR) I have hacked up a fix to the problem with line numbers being off +3) (BLR) I have hacked up a fix to the problem with line numbers being off due to statements sharing/spanning lines. The parser now stores the starting line number for all tuples, not just the splatted ones. Not only does this give synchronized lines in the comments in @@ -59,7 +55,7 @@ BR = Brian Raiter statement proper. So if a statement has its preamble on one line and the rest of it on the next, the preamble will be beheaded. - Still, it's a vast improvement, and as LLH points out, it's not + Still, it's a vast improvement, and as LHH points out, it's not going to get much better without writing a preprocessing lexer that can actually separate out the statements before any real parsing begins. Until someone wants to do that, this will do nicely, I think. @@ -70,6 +66,24 @@ BR = Brian Raiter statement, the last part will get truncated. Again, not a case we want to be encouraging people to explore anyway.) +4) (BLR) Interleave does not check the type of its arguments. The manual + insinuates that interleaving 32-bit values should result in error 533; + instead, C-INTERCAL silently truncates them to 16 bits. Unfortunately, + the modified behavior of select's return type depends on this, so + there's not much we can do about it as things stand. + +5) (BLR) An array can't have sparks or ears in its subscript list after the + first dimension. That is to say, this: + + DO ,1SUB'#1'#1 <- #0 + + works fine, but this: + + DO ,1SUB#1'#1' <- #0 + + doesn't parse, and gets treated as a syntax error (thus it is likely + to be a problem with the grammar). + TO DO 1. (ESR) Add more optimization templates, esp. idioms for +, -, *, /. diff --git a/Makefile b/Makefile index 0dce335..58d931b 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ # # Utility productions for the INTERCAL distribution # -VERSION = 0.15 +VERSION = 0.16 MANIFEST = `sed that port - this code to Linux and enable it to use flex. Note: This version has - been tested on Linux and SunOS but not yet elsewhere. + this code to Linux, ANSIfies it, and enables it to use flex. Note: This + version has been tested on Linux and SunOS but not yet elsewhere. 2. Another piece of nontrivial INTERCAL code has been found! (Doubtless hell is freezing over even as I write.) We've added to the pit the diff --git a/READ.ME b/READ.ME index 0c14593..055cf1d 100644 --- a/READ.ME +++ b/READ.ME @@ -9,9 +9,7 @@ live it down. This implementation was created by Eric S. Raymond during a fit of lunacy from which he has since mostly recovered. It has been considerably hacked upon and improved by Steve Swales, Michael Ernst, -Louis Howell (who wrote the array support stubbed out in Eric's original -version), and others. Brian Raiter ported it to Linux (doing ANSI cleanup -along the way), enabled it to use flex, and proofed the manual. +Louis Howell, Brian Raiter, and others. For detailed credits see NEWS. FILES @@ -38,13 +36,15 @@ src/ick.y -- the grammar specification (in YACC) src/ick.h -- compilation types and defines src/perpetrate.c -- main routine for compiler src/feh.c -- INTERCAL-to-C code generator +src/feh.h -- interface to INTERCAL-to-C code generator src/fiddle.c -- the INTERCAL operators src/lose.[ch] -- INTERCAL compile- and run-time error handling src/ick-wrap.c -- the driver for generated C-from-INTERCAL code src/arrgghh.c -- option argument parsing for generated programs +src/abcess.h -- interface to functions linked with programs src/cesspool.c -- the INTERCAL runtime support code -src/cesspool.h -- interface to INTERCAL runtime support src/numerals.c -- numerals table for INTERCAL input +src/sizes.h -- variables defining the numeric base pit/* -- sample INTERCAL code; see pit/CATALOG diff --git a/doc/Makefile b/doc/Makefile index b256a5b..6a134a5 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -8,34 +8,38 @@ # We make two passes in order to resolve SETR/GETNH references. # The sed hackery strips the trailing dots from level 1 section references. +x.txt: x.mm + groff -dc=y -Tascii -p -t -mm x.mm >x.txt + + all: intercal.ps intercal.txt original.ps original.txt intercal.ps: intercal.mm - groff -dc=y -Tps -p -t -mgm intercal.mm >/dev/null + groff -dc=y -Tps -p -t -mm intercal.mm >/dev/null sed tmp.refs; mv tmp.refs intercal.refs.tmp - groff -dc=y -Tps -p -t -mgm intercal.mm >intercal.ps + groff -dc=y -Tps -p -t -mm intercal.mm >intercal.ps rm intercal.refs.qrf original.ps: intercal.mm - groff -dc=n -Tps -p -t -mgm intercal.mm >/dev/null + groff -dc=n -Tps -p -t -mm intercal.mm >/dev/null sed tmp.refs; mv tmp.refs intercal.refs.tmp - groff -dc=n -Tps -p -t -mgm intercal.mm >original.ps + groff -dc=n -Tps -p -t -mm intercal.mm >original.ps rm intercal.refs.qrf intercal.txt: intercal.mm - groff -dc=y -Tascii -p -t -mgm intercal.mm >/dev/null + groff -dc=y -Tascii -p -t -mm intercal.mm >/dev/null sed tmp.refs; mv tmp.refs intercal.refs.tmp - groff -dc=y -Tascii -p -t -mgm intercal.mm >intercal.txt + groff -dc=y -Tascii -p -t -mm intercal.mm >intercal.txt rm intercal.refs.qrf original.txt: intercal.mm - groff -dc=n -Tascii -p -t -mgm intercal.mm >/dev/null + groff -dc=n -Tascii -p -t -mm intercal.mm >/dev/null sed tmp.refs; mv tmp.refs intercal.refs.tmp - groff -dc=n -Tascii -p -t -mgm intercal.mm >original.txt + groff -dc=n -Tascii -p -t -mm intercal.mm >original.txt rm intercal.refs.qrf clean: diff --git a/doc/READ.ME b/doc/READ.ME index 0ab4c90..25ac8ed 100644 --- a/doc/READ.ME +++ b/doc/READ.ME @@ -3,7 +3,7 @@ This directory contains the documentation (such as it is) for INTERCAL. READ.ME This file. -intercal.ms: +intercal.mm: Masters for the INTERCAL manual (needs pic to render illos) This has been carefully proofread against the original paper version. @@ -23,7 +23,7 @@ into the intercal manual. (It is still possible to generate the original; see the Makefile.) Note 3: The flat-ASCII directly transcribed from the paper original is -also gone. You can regenerate something very close to it with \&`make +also gone. You can regenerate something very close to it with `make original.txt'. The differences will be (a) page breaks may fall in different places, (b) the circuit diagrams present in the paper version but absent in the ASCII transcription are instead poorly diff --git a/doc/intercal.mm b/doc/intercal.mm index c6b5400..d6d967a 100644 --- a/doc/intercal.mm +++ b/doc/intercal.mm @@ -1,6 +1,8 @@ .\" Note: This is both a current manual and an archeological exhibit. .\" All revisions must be properly conditioned on the c string so that -.\" it's still possible to format the INTERCAL-72 manual. +.\" it's still possible to format the INTERCAL-72 manual. Only outright +.\" errors should be corrected -- each of these is marked with CORRECTION +.\" and an explanatory comment. .\" .\" This document is free; you can redistribute it and/or modify .\" it under the terms of the GNU General Public License as published by @@ -54,11 +56,11 @@ THE INTERCAL PROGRAMMING LANGUAGE and James M. Lyon\fR .if '\*c'y' \{\ .ce 2 -\fICopyright (C) 1996 by Eric S. Raymond +\fICopyright (C) 1996, 1997 by Eric S. Raymond Redistribution encouraged under GPL\} .sp .ce 1 -(This version distributed with C-INTERCAL 0.15) +(This version distributed with C-INTERCAL 0.16) .AE .MT 4 .nr % 0 @@ -66,6 +68,17 @@ Redistribution encouraged under GPL\} .nr Ej 1 .bp .H 1 "INTRODUCTION" +.if '\*c'y' \{\ +.DS I F +"But I don't want to go among mad people," Alice remarked. +.P +"Oh, you ca'n't help that," said the Cat: "We're all mad here. I'm +mad. You're mad." +.P +"How do you know I'm mad?" said Alice. +.P +"You must be," said the Cat, "or you wouldn't have come here." +.DE \} .P The names you are about to ignore are true. However, the story has been changed significantly. Any resemblance of the programming language portrayed here @@ -78,13 +91,13 @@ in the morning will become apparent in the course of this manual. .ie '\*c'y' \{\ .P Eighteen years later (give or take a few months) Eric S. Raymond perpetrated -a UNIX-hosted INTERCAL compiler as a weekend hack. The C-INTERCAL +a UNIX-hosted INTERCAL compiler as a weekend hack. The C-INTERCAL implementation has since been maintained and extended by an international community of technomasochists, including Louis Howell, Steve Swales, Michael Ernst, and Brian Raiter. .P (There was evidently an Atari implementation sometime between these -two; notes on it got appended to the INTERCAL-72 manual. The culprits +two; notes on it got appended to the INTERCAL-72 manual. The culprits have sensibly declined to identify themselves.) .P INTERCAL \} @@ -107,6 +120,18 @@ The authors are deeply indebted to Eric M. Van and Daniel J. Warmenhoven, without whose unwitting assistance this manual would still have been possible. .H 1 "FUNDAMENTAL CONCEPTS" +.if '\*c'y' \{\ +.DS I F +"There's nothing like eating hay when you're faint," the White King +remarked to Alice, as he munched away. +.P +"I should think throwing cold water over you would be better," Alice +suggested: "-- or some sal-volatile." +.P +"I didn't say there was nothing \fIbetter\fR," the King replied. "I +said there was nothing \fIlike\fR it." Which Alice did not venture to +deny. +.DE \} .P In this section an attempt is made to describe how and why INTERCAL may be used; i.e., what it is like and what it is good for. @@ -124,6 +149,9 @@ be greatly simplified if the subroutine library (see section A more detailed analysis of a program is made in section .GETHN proghints of this manual. +.\" Note: there was an error in line 15 in the original manual; +.\" the operands of the third \(ct were swapped. + .DS L .cs R 24 DO (5) NEXT @@ -140,7 +168,7 @@ A more detailed analysis of a program is made in section DO .1 <- "\*(vb':1~:2'\*(ct#1"~#3 DO :1 <- "'\*(vb":1~'#65535\*(ct#0'"\*(ct":2~'#65535 \*(ct#0'"'~'#0\*(ct#65535'"\*(ct"'\*(vb":1~'#0 - \*(ct#65535'"\*(ct":2~'#65535\*(ct#0'"'~'#0\*(ct#65535'" + \*(ct#65535'"\*(ct":2~'#0\*(ct#65535'"'~'#0\*(ct#65535'" DO (1) NEXT DO :2 <- ":2~'#0\*(ct#65535'" \*(ct"'":2~'#65535\*(ct#0'"\*(ct#0'~'#32767\*(ct#1'" @@ -168,7 +196,9 @@ INTERCAL is more useful (which isn't saying much) as a challenge to professional programmers. Those who doubt this need only refer back to the sample program in section .GETHN example1 -\&. This 22-statement program took somewhere +.\" CORRECTION: +.\" The original manual counted 22 statements, incorrectly. +\&. This 23-statement program took somewhere from 15 to 30 minutes to write, whereas the same objectives can be achieved by single-statement programs in either SNOBOL; .DS L @@ -200,6 +230,22 @@ front of his boss, who would of course happened to turn up, as bosses are wont to do. The effect would be no less devastating for the programmer having been correct. .H 1 "DESCRIPTION" +.if '\*c'y' \{\ +.DS I F +"I quite agree with you," said the Duchess; "and the moral of that +is -- 'Be what you would seem to be' -- or, if you'd like it put more +simply -- 'Never imagine yourself not to be otherwise than what it might +appear to others that what you were or might have been was not +otherwise than what you had been would have appeared to them to be +otherwise." +.P +"I think I should understand that better," Alice said very politely, +"if I had it written down: but I ca'n't quite follow it as you say +it." +.P +"That's nothing to what I could say if I chose," the Duchess replied, +in a pleased tone. +.DE \} .P The examples of INTERCAL programming which have appeared in the preceding sections of this manual have probably seemed highly esoteric to the reader @@ -216,7 +262,7 @@ These are represented by a spot (.) or two-spot These variables may contain only non-negative numbers; thus they have the respective ranges of values: 0 to 65535 and 0 to 4294967295. Note: .123 and :123 are two distinct variables. On the other hand, .1 and .0001 are -identical. Furthermore, the latter may NOT be written as 1E-3. +identical. Furthermore, the latter may \fInot\fR be written as 1E-3. .H 2 "Constants" .P .B Constants @@ -236,21 +282,28 @@ constructions, which are resolved as discussed in section \&. Definition of array dimensions will be discussed later in greater detail, since discussing it in less detail would be difficult. As before, ,123 and ;123 -are distinct. In summary, .123, :123, #123, ,123, and :123 are all +are distinct. In summary, .123, :123, #123, ,123, and ;123 are all distinct. .H 2 "Operators" .P -INTERCAL recognizes 5 operators -- 2 binary and 3 unary. Please be kind to +INTERCAL recognizes 5 operators -- 2 binary and 3 unary \*F. Please be kind to our operators: they may not be very intelligent, but they're all we've got. In a sense, all 5 operators are binary, as they are all bit-oriented, but it is not our purpose here to quibble about bits of trivia. +.if '\*c'y' \{\ +.FS +Other operators are also available with C-INTERCAL's non-standard +dialects; see section +.GETHN tri_intercal +\&. +.FE \} .H 3 "Binary Operators" .P The binary operators are \fBinterleave\fR (also called \fBmingle\fR) and \fBselect\fR, which are represented by a change (\*(ct) and a sqiggle [sic] (~), respectively. .if '\*c'y' \{\ -(In C-INTERCAL'S ASCII environment, EBCDIC \*(ct is replaced by a big +(In C-INTERCAL's ASCII environment, EBCDIC \*(ct is replaced by a big money ($).) \} .P The interleave operator takes two 16-bit values and produces a 32-bit result @@ -269,39 +322,12 @@ selects from the first argument the 8th, 7th, 4th, and 1st from last bits, namely, 1001, which = 9. But #201~#179 selects from binary 11001001 the 8th, 6th, 5th, 2nd, and 1st from last bits, giving 10001 = 17. #179~#179 has the value 31, while #201~#201 has the value 15. -.if '\*c'y' \{\ -.H 4 "Return type of SELECT" -.P -INTERCAL-72 defined the return type of a SELECT operation -to depend on the number of bits SELECTed. The C-INTERCAL compiler -takes the easier route of defining the return type to be that of -the right operand, independent of its actual value. This form has -the advantage that all types can be determined at compile time. -Putting in run time type checking would add significant overhead and -complication, to effect a very minor change in language semantics. -.P -The only time this distinction makes any difference is when a unary -operator is applied to the SELECT result. This happens extremely -rarely in practice, the only known instance being the 32-bit -greater-than test in the standard library, where an XOR operator is -applied to the result of SELECTing a number against itself. The -INTERCAL-72 authors first SELECT the result against #65535\*(ct#65535 to -insure that XOR sees a 32-bit value. With the current compiler this -extra step is unnecessary, but harmless. -.P -The cautious programmer should write code that does not depend on -the compiler version being used. We therefore suggest the following -guideline for determining the SELECT return type: -.P -A SELECT operation with a 16-bit right operand returns a 16-bit -value. The return type of a SELECT operation with a 32-bit right -operand is undefined, but is guaranteed to be an acceptable input -to a MINGLE operation so long as 16 or fewer bits are actually -selected. Correct code should not depend on whether the return -type is 16 or 32 bits.\} .P Perhaps a simpler way of understanding the operation of the select operator -would be to examine the logic diagram on the following page (Figure 1), which +.\" CORRECTION: +.\" "in Figure 1" was originally "on the following page (Figure 1)" +.\" We can't rely on the page boundaries any more. +would be to examine the logic diagram in Figure 1, which performs the select operation upon two 8-bit values, A and B. The gates used are Warmenhovian logic gates, which means the outputs have four possible values: low, high, undefined (value of an uninitialized flip-flop), and @@ -320,7 +346,7 @@ Get a better output device.] # The CIRCUITOUS DIAGRAM, Figure 1 of the INTERCAL manual. # # Transcribed to PIC by Eric S. Raymond from the paper original. -# The transcription to topologically correct but not geometrically perfect. +# The transcription is topologically correct but not geometrically perfect. # # I discovered late in the process that the gate spacing to gate width # ratio should be 6/5, not 5/5. The only place the difference shows is @@ -934,12 +960,42 @@ move right from last [].w; box invis wid 6 \ "GATE TYPE 9. BLACK BOX" ljust \ "INPUTS A1-8, B1-8. " ljust \ - "OUTPUT D1-8 = A1-8~B1=8" ljust + "OUTPUT O1-8 = A1-8~B1-8" ljust .PE .sp 10 .ce 1 FIGURE 1 (CONTINUED). NEW YORK .bp +.if '\*c'y' \{\ +.H 4 "Return type of SELECT" +.P +INTERCAL-72 defined the return type of a select operation +to depend on the number of bits selected. The C-INTERCAL compiler +takes the easier route of defining the return type to be that of +the right operand, independent of its actual value. This form has +the advantage that all types can be determined at compile time. +Putting in run-time type-checking would add significant overhead and +complication, to effect a very minor change in language semantics. +.P +The only time this distinction makes any difference is when a unary +operator is applied to the select result. This happens extremely +rarely in practice, the only known instance being the 32-bit +greater-than test in the standard library, where an XOR operator is +applied to the result of selecting a number against itself. The +INTERCAL-72 authors first select the result against #65535\*(ct#65535 to +insure that XOR sees a 32-bit value. With the current compiler this +extra step is unnecessary, but harmless. +.P +The cautious programmer should write code that does not depend on +the compiler version being used. We therefore suggest the following +guideline for determining the select return type: +.P +A select operation with a 16-bit right operand returns a 16-bit +value. The return type of a select operation with a 32-bit right +operand is undefined, but is guaranteed to be an acceptable input +to a mingle operation so long as 16 or fewer bits are actually +selected. Correct code should not depend on whether the return +type is 16 or 32 bits.\} .H 3 "Unary Operators" .P The unary operators are & (logical \fBAND\fR), V (logical \fBOR\fR), @@ -947,10 +1003,9 @@ and \*(vb (logical \fBXOR\fR). This last character is obtained by overpunching a worm (\-) on a V (V). .if '\*c'y' \{\ -(In C-INTERCAL'S ASCII environment, EBCDIC \*(vb is replaced by the -what (?). The compiler recognizes -V as a valid -equivalent, in case you are concerned about compatibility with the -Princeton compiler.) \} +(In C-INTERCAL, \*(vb is replaced by what (?). The compiler recognizes +V- as a valid equivalent, in case you are concerned about +compatibility with the Princeton compiler.) \} The operator is inserted between the spot, two-spot, mesh, or what-have-you, and the integer, thus: .&123, #\*(vb123. Multiple unary operators may not be concatenated, thus the form #\*(vb&123 is invalid. This @@ -1008,6 +1063,21 @@ also section .GETHN princeton \&. .H 1 "STATEMENTS" +.if '\*c'y' \{\ +.DS I F +"There's glory for you!" +.P +"I don't know what you mean by 'glory,'" Alice said. +.P +Humpty Dumpty smiled contemptuously. "Of course you don't -- till I tell +you. I meant 'there's a nice knock-down argument for you!'" +.P +"But 'glory' doesn't mean 'a nice knock-down argument.'" Alice +objected. +.P +"When \fII\fR use a word," Humpty Dumpty said, in a rather scornful +tone, "it means just what I choose it to mean -- neither more nor less." +.DE \} .P In this section is described the format of INTERCAL statements. .H 2 "General Format" @@ -1066,7 +1136,12 @@ of being executed each time it is encountered in the course of execution. .H 2 "Statements" .P Following the qualifiers (or, if none are used, the identifier) must occur -one of the 13 valid operations. (Exception: see section +one of the +.ie '\*c'y' \{\ +14 \} +.el \{\ +13 \} +valid operations. (Exception: see section .GETHN comments \&.) These are described individually in sections @@ -1085,7 +1160,7 @@ assigned 32-bit values only if the value is less than 65535. Thus, to invert the least significant bit of the first element of 16-bit 2-dimensional array number 1, one could write: .DS -,1SUB#1#1 <- '\*(vb,1SUB#1#1\*(ct#1'~'#0\*(ct#65535' +,1SUB#1#1 <- '\*(vb",1SUB#1#1"\*(ct#1'~'#0\*(ct#65535' .DE Similarly to SNOBOL and SPITBOL, INTERCAL uses the angle-worm to define the dimensions of arrays. An example will probably best describe the format. @@ -1177,7 +1252,7 @@ performed by a sequence of the form: .cs R .DE Unlike the FORGET statement, an attempt to RESUME more levels of NEXTing than -been stacked will cause program termination. See also section +has been stacked will cause program termination. See also section .GETHN give_up \&. .H 3 "STASH" @@ -1234,17 +1309,23 @@ available for use in expressions and the like. Though the INTERCAL-72 manual laid down that the value of an IGNOREd variable cannot change, it was unclear about whether or not a statement which appears to change an IGNOREd variable is executed or -not. This may appear to be a "If a tree falls in the forest..." type +not. This may appear to be a "If a tree falls in the forest ..." type of question, but if the statement in question has other side effects it is not. .P Since another mechanism already exists for ABSTAINing from a statement, C-INTERCAL's IGNORE only prevents the changing of the specific variable in question, not the execution of the entire -statement. In the present version of the language this only makes -a difference for the WRITE IN statement. Attempting to WRITE IN +statement. In the present version of the language this only makes +a difference for the WRITE IN (see +.GETHN input +) and RETRIEVE (see +.GETHN retrieve +) statements. Attempting to WRITE IN to an IGNOREd variable will cause a number to be read from the input, -which will be discarded since it cannot be stored in the variable. \} +which will be discarded since it cannot be stored in the variable. +Using RETRIEVE on an IGNOREd variable will pop the variable's stash +stack without actually changing its value. \} .H 3 "REMEMBER" .SETR remember .P @@ -1270,10 +1351,11 @@ time. DO ABSTAIN FROM (label) causes the statement whose logical line label is (label) to be abstained from. PLEASE ABSTAIN FROM gerund list causes all statements of the specified type(s) to be abstained from, as in .DS L - PLEASE ABSTAIN FROM STASHING - PLEASE ABSTAIN FROM IGNORING + FORGETTING - PLEASE ABSTAIN FROM NEXTING - or PLEASE ABSTAIN FROM CALCULATING +.ta .3i .6i T .6i + PLEASE ABSTAIN FROM STASHING + PLEASE ABSTAIN FROM IGNORING + FORGETTING + PLEASE ABSTAIN FROM NEXTING + or PLEASE ABSTAIN FROM CALCULATING .DE Statements may also be automatically abstained from at the start of execution via the NOT or N'T parameter (see section @@ -1323,7 +1405,7 @@ statement. .SETR input .P Input is accomplished with the statement DO WRITE IN list, where list -represents a string of variables and/or elements or arrays, separated by +represents a string of variables and/or elements of arrays, separated by intersections. Numbers are represented on cards, each number on a separate card, by spelling out each digit (in English) and separating the digits with one or more spaces. A zero (0) may be spelled as either ZERO or OH. @@ -1331,13 +1413,18 @@ Thus the range of (32-bit) input values permissible extends from ZERO (or OH) through FOUR TWO NINE FOUR NINE SIX SEVEN TWO NINE FIVE. .if '\*c'y' \{\ (For the convenience of aviators, C-INTERCAL accepts the spelling -NINER for NINE. In the service of internationalization, C-INTERCAL +NINER for NINE. In the service of internationalization, C-INTERCAL also accepts input digits in Sanskrit, Basque, Tagalog, Classical -Nahuatl, Georgian, Kwakiutl, and Volapuk. \} +Nahuatl, Georgian, Kwakiutl, and Volapuk.) \} .P Attempting to write in a value greater than or equal to SIX FIVE FIVE THREE SIX for a 16-bit variable will result in the error message, "DON'T BYTE OFF MORE THAN YOU CAN CHEW." +.if '\*c'y' \{\ +.P +(See also section +.GETHN communication + for a description of C-INTERCAL's character I/O.) \} .H 3 "Output" .P Values may be output to the printer, one value per line, via the statement @@ -1402,6 +1489,11 @@ i .fi \} for 1000000000. .if '\*c'y' \{\ +.P +(See also section +.GETHN communication + for a description of C-INTERCAL's character I/O.) \} +.if '\*c'y' \{\ .H 3 "COME FROM" .P In which we try to precisely define a statement that should never @@ -1411,16 +1503,16 @@ in INTERCAL. .P The earliest known description of the COME FROM statement in the computing literature is in [R. L. Clark, "A linguistic contribution to GOTO-less -programming," Commun. ACM 27 (1984), pp. 349--350], part of the famous April -Fools issue of CACM. The subsequent rush by language designers to include the +programming," Commun. ACM 27 (1984), pp. 349-350], part of the famous April +Fools issue of CACM. The subsequent rush by language designers to include the statement in their languages was underwhelming, one might even say nonexistent. It was therefore decided that COME FROM would be an appropriate addition to C-INTERCAL. .H 4 "Description" .P There are two useful ways to visualize the action of the COME FROM -statement. The simpler is to see that it acts like a GOTO when the -program is traced backwards in time. More precisely, the statements +statement. The simpler is to see that it acts like a GOTO when the +program is traced backwards in time. More precisely, the statements .DS L (1) DO . @@ -1442,15 +1534,15 @@ doesn't. .P What this boils down to is that the statement DO COME FROM (label), anywhere in the program, places a kind of invisible trap door -immediately after statement (label). Execution or abstention of that +immediately after statement (label). Execution or abstention of that statement is immediately followed by an unconditional jump to the COME FROM, unless the (label)ed statement is an executed NEXT, in which case the jump occurs if the program attempts to RESUME back to that -NEXT statement. It is an error for more than one COME FROM to refer +NEXT statement. It is an error for more than one COME FROM to refer to the same (label). .P Modification of the target statement by ABSTAIN or by the % qualifier -affects only that statement, not the subsequent jump. Such +affects only that statement, not the subsequent jump. Such modifications to the COME FROM itself, however, do affect the jump. Encountering the COME FROM statement itself, rather than its target, has no effect. \} @@ -1484,8 +1576,11 @@ as are certain simple conditional errors: .DE This pair of statements will cause an error exit the second time they are encountered. Caution!! The appearance of a statement identifier in an -intended comment will be taken as the beginning of a new statement. Thus, -the first example on the preceding page could not have been: +intended comment will be taken as the beginning of a new +.\" CORRECTION: +.\" "comment example above" was originally "example on the preceding page" +.\" We can't rely on page boundaries any more. +statement. Thus, the first comment example above could not have been: .sp 1 * PLEASE NOTE THAT THIS LINE DOES NOTHING .P @@ -1494,54 +1589,61 @@ of D-space-O, since INTERCAL does not ignore extraneous spaces in statement identifiers. .if '\*c'y' \{\ .H 1 "OUTSIDE COMMUNICATION" +.if '\*c'y' \{\ +.DS I F +She puzzled over this for some time, but at last a bright thought +struck her. "Why, it's a Looking-glass book, of course! And, if I hold +it up to a glass, the words will all go the right way again." +.DE \} +.SETR communication .P In which we try to remedy the fact that, due to I/O limitations, INTERCAL -can not even in principle perform the same tasks as other languages. It +can not even in principle perform the same tasks as other languages. It is hoped that this addition will permit INTERCAL users to waste vast quantities of computer time well into the 21st century. .H 2 "Motivation" .P One of the goals of INTERCAL was to provide a language which, though different from all other languages, is nevertheless theoretically -capable of all the same tasks. INTERCAL-72 failed to +capable of all the same tasks. INTERCAL-72 failed to accomplish this because its I/O functions could not handle arbitrary -streams of bits, or even arbitrary sequences of characters. A +streams of bits, or even arbitrary sequences of characters. A language which can't even send its input directly to its output can hardly be considered as capable as other languages. .H 2 "Turing Text Model" .P To remedy this problem, character I/O is now provided in a form based -on the "Turing Text" model, originally proposed by Jon Blow. The -C-INTERCAL programmer can access this capability by placing a one- -dimensional array in the list of items given to a WRITE IN or READ OUT -statement. On execution of the statement, the elements of the array +on the "Turing Text" model, originally proposed by Jon Blow. The +C-INTERCAL programmer can access this capability by placing a +one-dimensional array in the list of items given to a WRITE IN or READ +OUT statement. On execution of the statement, the elements of the array will, from first to last, be either loaded from the input or sent -to the output, as appropriate, in the manner described below. There +to the output, as appropriate, in the manner described below. There is currently no support for I/O involving higher-dimensional arrays, but some form of graphics might be a possible 2-D interpretation. .P The heart of the Turing Text model is the idea of a continuous loop of tape containing, in order, all the characters in the machine's -character set. When a character is received by the input routine, +character set. When a character is received by the input routine, the tape is advanced the appropriate number of spaces to bring that character under the tape head, and the number of spaces the tape was moved is the number that is actually seen by the INTERCAL -program. Another way to say this is that the number placed in an +program. Another way to say this is that the number placed in an INTERCAL array is the difference between the character just received and the previous character, modulo the number of characters in the machine character set. .P Output works in just the opposite fashion, except that the characters -being output come from the other side of the tape. From this position +being output come from the other side of the tape. From this position the characters on the tape appear to be in reverse order, and are -individually backwards as well. (We would show you what it looks +individually backwards as well. (We would show you what it looks like, but we don't have a font with backwards letters available. -Use your imagination.) The effect is that a number is taken out -of an INTERCAL array, subtracted from the last character output--- -i.e., the result of the last subtraction---and then sent on down -the output channel. The only catch is that the character as seen +Use your imagination.) The effect is that a number is taken out +of an INTERCAL array, subtracted from the last character output -- +i.e., the result of the last subtraction -- and then sent on down +the output channel. The only catch is that the character as seen by the INTERCAL program is the mirror-image of the character as -seen by the machine and the user. The bits of the character are +seen by the machine and the user. The bits of the character are therefore taken in reverse order as it is sent to the output. Note that this bit reversal affects only the character seen by the outside world; it does not affect the character stored internally @@ -1549,21 +1651,22 @@ by the program, from which the next output number will be subtracted. All subtractions are done modulo the number of characters in the character set. .P -Two different tapes are used for input and for output to allow for +Two different tapes are used for input and output to allow for future expansion of the language to include multiple input and -output channels. Both tapes start at character 0 when a program -begins execution. On input, when an end of file marker is reached -the number placed in the array is one greater than the highest- -numbered character on the tape. +output channels. Both tapes start at character 0 when a program +begins execution. On input, when an end-of-file marker is reached +the number placed in the array is one greater than the +highest-numbered character on the tape. .H 2 "Example Program" .P If all this seems terribly complicated, it should be made perfectly clear by the following example program, which simply maps its input -to its output (like a simplified UNIX "cat"). It assumes that +to its output (like a simplified UNIX "cat"). It assumes that characters are 8 bits long, but that's fine since the current version -of C-INTERCAL does too. It uses the standard library routines for addition +of C-INTERCAL does too. It uses the standard library routines for addition and subtraction. .DS L +.cs R 24 DO ,1 <- #1 DO .4 <- #0 DO .5 <- #0 @@ -1586,59 +1689,68 @@ and subtraction. DO .5 <- .2 DO ,1SUB#1 <- .3 (30) PLEASE READ OUT ,1 +.cs R .DE For each number received in the input array, the program first tests -the #256 bit to see if the end of file has been reached. If not, the +the #256 bit to see if the end of file has been reached. If not, the previous input character is subtracted off to obtain the current -input character. Then the order of the bits is reversed to find +input character. Then the order of the bits is reversed to find out what character should be sent to the output, and the result -is subtracted from the last character sent. Finally, the difference -is placed in an array and given to a READ OUT statement. See? +is subtracted from the last character sent. Finally, the difference +is placed in an array and given to a READ OUT statement. See? We told you it was simple! \} .if '\*c'y' \{\ .H 1 "TriINTERCAL" +.if '\*c'y' \{\ +.DS I F +"-- oh dear, how puzzling it all is! I'll try if I know all the things +I used to know. Let me see: four times five is twelve, and four times +six is thirteen, and four times seven is -- oh dear! I shall never get +to twenty at that rate!" +.DE \} +.SETR tri_intercal .P In which it is revealed that bitwise operations are too ordinary for hard-core INTERCAL programmers, and extensions to other bases are -discussed. These are not, strictly speaking, extensions to INTERCAL +discussed. These are not, strictly speaking, extensions to INTERCAL itself, but rather new dialects sharing most of the features of the parent language. .H 2 "Motivation" .P -INTERCAL is really a pretty sissy language. It tries hard to be +INTERCAL is really a pretty sissy language. It tries hard to be different, but when you get right down to its roots, what do you find? -You find bits, that's what. Plain old ones and zeroes, in groups of -16 and 32, just like every other language you've ever heard of. And -what operations can you perform on these bits? The INTERCAL operators +You find bits, that's what. Plain old ones and zeroes, in groups of +16 and 32, just like every other language you've ever heard of. And +what operations can you perform on these bits? The INTERCAL operators may arrange and permute them in weird and wonderful ways, but at the bit level the operators are the same AND, OR and XOR you've seen countless times before. .P Once the prospective INTERCAL programmer masters the unusual syntax, she finds herself working with the familiar Boolean operators on -perfectly ordinary unsigned integer words. Even the constants she uses -are familiar. After all, who would not immediately recognize #65535 -and #32768? It may take a just a moment more to figure out #65280, +perfectly ordinary unsigned integer words. Even the constants she uses +are familiar. After all, who would not immediately recognize #65535 +and #32768? It may take a just a moment more to figure out #65280, and #21845 and #43690 could be puzzles until she notices that they -sum to #65535, but basically she's still on her home turf. The 16-bit +sum to #65535, but basically she's still on her home turf. The 16-bit limit on constants actually works in the programmer's favor by insuring -that very long anonymous constants can not appear in INTERCAL programs. +that very long anonymous constants cannot appear in INTERCAL programs. And this is in a language that is supposed to be different from any other! .H 2 "Abandon All Hope..." .P Standard INTERCAL is based on variables consisting of ordinary bits -and familiar Boolean operations on those bits. In pursuit of uniqueness, +and familiar Boolean operations on those bits. In pursuit of uniqueness, it seems appropriate to provide a new dialect, otherwise identical to INTERCAL, which instead uses variables consisting of trits, i.e. ternary -digits, and operators based on tritwise logical operations. This is +digits, and operators based on tritwise logical operations. This is intended to be a separate dialect, rather than an extension to INTERCAL -itself, for a number of reasons. Doing it this way avoids word-length +itself, for a number of reasons. Doing it this way avoids word-length conflicts, does not spoil the elegance of the Spartan INTERCAL operator set, and dodges the objections of those who might feel it too great an -alteration to the original language. Primarily, though, giving INTERCAL +alteration to the original language. Primarily, though, giving INTERCAL programmers the ability to switch numeric base at will amounts to -excessive functionality. So much better that a programmer choose a base +excessive functionality. So much better that a programmer choose a base at the outset and then be forced to stick with it for the remainder of the program. .H 2 "Compiler Operation" @@ -1647,183 +1759,182 @@ The same compiler, ick, supports both INTERCAL and TriINTERCAL. This has the advantage that future bug fixes and additions to the language not related to arithmetic immediately apply to both versions. The compiler recognizes INTERCAL source files by the extension '.i', -and TriINTERCAL source files by the extension '.3i'. It's as simple -as that. There is no way to mix INTERCAL and TriINTERCAL source in +and TriINTERCAL source files by the extension '.3i'. It's as simple +as that. There is no way to mix INTERCAL and TriINTERCAL source in the same program, and it is not always possible to determine which dialect a program is written in just by looking at the source code. .H 2 "Data Types" .P The two TriINTERCAL data types are 10-trit unsigned integers and -20-trit unsigned integers. All INTERCAL syntax for distinguishing -data types is ported to these new types in the obvious way. Small -words may contain numbers from #0 to #59048, large words may contain -numbers from #0$#0 to #59048$#59048. Errors are signaled for constants +20-trit unsigned integers. All INTERCAL syntax for distinguishing +data types is ported to these new types in the obvious way. Small +words may contain numbers from #0 to #59048; large words may contain +numbers from #0$#0 to #59048$#59048. Errors are signaled for constants greater than #59048 and for attempts to WRITE IN numbers too large for a given variable or array element to hold. .P Note that though TriINTERCAL considers all numbers to be unsigned, nothing prevents the programmer from implementing arithmetic operations -that treat their operands as signed. Three's complement is one obvious -choice, but balanced ternary notation is also a possibility. This +that treat their operands as signed. Three's complement is one obvious +choice, but balanced ternary notation is also a possibility. This latter is a very pretty and symmetrical system in which all 2 trits are treated as if they had the value -1. .H 2 "Operators" .P The TriINTERCAL operators are designed to inherit the relevant properties of the standard INTERCAL operators, so that both can be considered as -merely different aspects of the same Platonic ideal. (Not that the word +merely different aspects of the same Platonic ideal. (Not that the word "ideal" is ever particularly relevant when used in connection with INTERCAL.) .H 3 "Binary Operators I" .P The binary operators carry over from the original language with only -minor changes. The MINGLE operator ($) creates a 20-trit word by -alternating trits from its two 10-trit operands. The SELECT operator (~) +minor changes. The mingle operator ($) creates a 20-trit word by +alternating trits from its two 10-trit operands. The select operator (~) is a little more complicated, since the ternary tritmask may contain 0, 1, -and 2 trits. If we observe that the SELECT operation on binary operands +and 2 trits. If we observe that the select operation on binary operands amounts to a bitwise AND and some rearrangement of bits, it seems -appropriate to base the SELECT for ternary operands on a tritwise AND in -the analogous fashion. We therefore postpone the definition of SELECT +appropriate to base the select for ternary operands on a tritwise AND in +the analogous fashion. We therefore postpone the definition of select until we know what a tritwise AND looks like. .H 3 "Unary Operators" .P The unary operators in INTERCAL are all derived from the familiar -Boolean operations on single bits. To extend these operations to trits, +Boolean operations on single bits. To extend these operations to trits, we first ask ourselves what the important properties of these operations are that we wish to be preserved, then design the tritwise operators so that they behave in a similar fashion. .H 4 "Unary Logical Operators" .P -Let's start with AND and OR. To begin with, these can be considered +Let's start with AND and OR. To begin with, these can be considered "choice" or "preference" operators, as they always return one of their -operands. AND can be described as wanting to return 0, but returning 1 -if it is given no other choice, i.e., if both operands are 1. Similarly, -OR wants to return 1 but returns 0 if that is its only choice. From +operands. AND can be described as wanting to return 0, but returning 1 +if it is given no other choice, i.e., if both operands are 1. Similarly, +OR wants to return 1 but returns 0 if that is its only choice. From this it is immediately apparent that each operator has an identity element that "always loses", and a dominator element that "always wins". .P AND and OR are commutative and associative, and each distributes -over the other. They are also symmetric with each other, in the sense +over the other. They are also symmetric with each other, in the sense that AND looks like OR and OR looks like AND when the roles of 0 and 1 -are interchanged (De Morgan's Laws). This symmetry property seems to be +are interchanged (De Morgan's Laws). This symmetry property seems to be a key element to the idea that these are logical, rather than arithmetic, -operators. In a three-valued logic we would similarly expect a three- -way symmetry among the three values 0, 1 and 2 and the three operators -AND, OR and (of course) BUT. +operators. In a three-valued logic we would similarly expect a +three-way symmetry among the three values 0, 1 and 2 and the three +operators AND, OR and (of course) BUT. .P The following tritwise operations have all the desired properties: -OR returns the greater of its two operands. That is, it returns 2 if +OR returns the greater of its two operands. That is, it returns 2 if it can get it, else it tries to return 1, and it returns 0 only if both -operands are 0. AND wants to return 0, will return 2 if it can't get -0, and returns 1 only if forced. BUT wants 1, will take 0, and tries -to avoid 2. The equivalents to De Morgan's Laws apply to rotations -of the three elements, e.g., 0 -> 1, 1 -> 2, 2 -> 0. Each operator +operands are 0. AND wants to return 0, will return 2 if it can't get +0, and returns 1 only if forced. BUT wants 1, will take 0, and tries +to avoid 2. The equivalents to De Morgan's Laws apply to rotations +of the three elements, e.g., 0 -> 1, 1 -> 2, 2 -> 0. Each operator distributes over exactly one other operator, so the property -"X distributes over Y" is not transitive. The question of which way +"X distributes over Y" is not transitive. The question of which way this distributivity ring goes around is left as an exercise for the student. .P -In TriINTERCAL programs the whirlpool (@) symbol denotes the unary -tritwise BUT operation. You can think of the whirlpool as drawing -values preferentially towards the central value 1. Alternatively, -you can think of it as drawing your soul and your sanity inexorably -down... +In TriINTERCAL programs the whirlpool (@) denotes the unary tritwise +BUT operation. You can think of the whirlpool as drawing values +preferentially towards the central value 1. Alternatively, you can +think of it as drawing your soul and your sanity inexorably down ... .P On the other hand, maybe it's best you \fInot\fR think of it that way. .P -A few comments about how these operators can be used. OR acts like -a tritwise maximum operation. AND can be used with tritmasks. 0's +A few comments about how these operators can be used. OR acts like +a tritwise maximum operation. AND can be used with tritmasks. 0's in a mask wipe out the corresponding elements in the other operand, -while 1's let the corresponding elements pass through unchanged. 2's +while 1's let the corresponding elements pass through unchanged. 2's in a mask consolidate the values of nonzero elements, as both 1's and -2's in the other operand yield 2's in the output. BUT can be used to -create "partial tritmasks". 0's in a mask let BUT eliminate 2's from -the other operand while leaving other values unchanged. Of course, +2's in the other operand yield 2's in the output. BUT can be used to +create "partial tritmasks". 0's in a mask let BUT eliminate 2's from +the other operand while leaving other values unchanged. Of course, the symmetry property guarantees that the operators don't really behave differently from each other in any fundamental way; the apparent differences come from the intuitive view that a 0 trit is "not set" while a 1 or 2 trit is "set". .H 4 "Binary Operators II" .P -At this point we can define SELECT, since we now know what the -tritwise AND looks like. SELECT takes the binary tritwise AND of -its two operands. It shifts all the trits of the result corresponding +At this point we can define select, since we now know what the +tritwise AND looks like. Select takes the binary tritwise AND of +its two operands. It shifts all the trits of the result corresponding to 2's in the right operand over to the right (low) end of the result, then follows them with all the output trits corresponding to 1's in -the right operand. Trits corresponding to 0's in the right operand, +the right operand. Trits corresponding to 0's in the right operand, which are all 0 anyway, occupy the remaining space at the left end of -the output word. Both 10-trit and 20-trit operands are accepted, -and are padded with zeroes on the left if necessary. The output -type is determined the same way as in standard INTERCAL. +the output word. Both 10-trit and 20-trit operands are accepted, +and are padded with zeroes on the left if necessary. The output +type is determined the same way as in standard C-INTERCAL. .H 4 "Unary Arithmetic Operators" .P -Now that we've got all that settled, what about XOR? This is +Now that we've got all that settled, what about XOR? This is easily the most-useful of the three unary INTERCAL operators, because it combines in one package the operations ADD WITHOUT CARRY, -SUBTRACT WITHOUT BORROW, BITWISE NOT-EQUAL, and BITWISE NOT. In +SUBTRACT WITHOUT BORROW, BITWISE NOT-EQUAL, and BITWISE NOT. In TriINTERCAL we can't have all of these in the same operator, since -addition and subtraction are no longer the same thing. The solution -is to split the XOR concept into two operators. The ADD WITHOUT CARRY -operation is represented by the new sharkfin (^) symbol, while the -old what (?) symbol represents SUBTRACT WITHOUT BORROW. The reason for -this choice is so that what (?) will also represent the TRITWISE NOT-EQUAL +addition and subtraction are no longer the same thing. The solution +is to split the XOR concept into two operators. The ADD WITHOUT CARRY +operation is represented by the new sharkfin (^), while the old +what (?) represents SUBTRACT WITHOUT BORROW. The reason for this +choice is so that what (?) will also represent the TRITWISE NOT-EQUAL operation. .P Note that what (?), unlike the other four unary operators, is not -symmetrical. It should be thought of as rotating its operand one trit +symmetrical. It should be thought of as rotating its operand one trit to the right (with wraparound) and then subtracting off the trits of -the original number. These subtractions are done without borrowing, +the original number. These subtractions are done without borrowing, i.e., trit-by-trit modulo 3. .H 3 "Examples" .P The TriINTERCAL operators really aren't all that bad once you get -used to them. Let's look at a few examples to show how they can -be used in practice. In all of these examples the input value is +used to them. Let's look at a few examples to show how they can +be used in practice. In all of these examples the input value is contained in the 10-trit variable .3. .P In INTERCAL, single-bit values often have to be converted from -{0,1} to {1,2} for use in RESUME statements. Examples of how to do -this appear in the original manual. In TriINTERCAL the expression -"^.3$#1"~#1 sends 0 -> 1 and 1 -> 2. If the 1-trit input value can +{0,1} to {1,2} for use in RESUME statements. Examples of how to do +this appear in the original manual. In TriINTERCAL the expression +"^.3$#1"~#1 sends 0 -> 1 and 1 -> 2. If the 1-trit input value can take on any of its three possible states, however, we will also have -to deal with the 2 case. The expression "V.3$#1"~#1 sends {0,1} -> 1 -and 2 -> 2. To test if a trit is set, we can use "V'"&.3$#2"~#1'$#1"~#1, -sending 0 -> 1 and {1,2} -> 2. To reverse the test we use -"?'"&.3$#2"~#1'$#1"~#1, sending 0 -> 2 and {1,2} -> 1. Note that we -have not been taking full advantage of the new SELECT operator. These +to deal with the 2 case. The expression "V.3$#1"~#1 sends {0,1} -> 1 +and 2 -> 2. To test if a trit is set, we can use "V'"&.3$#2"~#1'$#1"~#1, +sending 0 -> 1 and {1,2} -> 2. To reverse the test we use +"?'"&.3$#2"~#1'$#1"~#1, sending 0 -> 2 and {1,2} -> 1. Note that we +have not been taking full advantage of the new select operator. These last two expressions can be simplified into "V!3~#2'$#1"~#1 and -"?!3~#2'$#1"~#1, which perform exactly the same mappings. Finally, if +"?!3~#2'$#1"~#1, which perform exactly the same mappings. Finally, if we need a 3-way test, we can use "@'"^.3$#7"~#4'$#2"~#10, which obviously sends 0 -> 1, 1 -> 2, and 2 -> 3. .P For an unrelated example, the expression "^.3$.3"~"#0$#29524" converts all of the 1-trits of .3 into 2's and all of the 2-trits -into 1's. In balanced ternary, where 2-trits represent -1 values, +into 1's. In balanced ternary, where 2-trits represent -1 values, this is the negation operation. .H 2 "Beyond Ternary..." .P While we're at it, we might as well extend this multiple bases -business a little farther. The ick compiler actually recognizes +business a little farther. The ick compiler actually recognizes filename suffixes of the form '.Ni', where N is any number from 2 -to 7. 2 of course gives standard INTERCAL, while 3 gives TriINTERCAL. +to 7. 2 of course gives standard INTERCAL, while 3 gives TriINTERCAL. We cut off before 8 because octal notation is the smallest base used to facilitate human-to-machine communication, and this seems quite -contrary to the basic principles behind INTERCAL. The small data +contrary to the basic principles behind INTERCAL. The small data types hold 16 bits, 10 trits, 8 quarts, 6 quints, 6 sexts, or 5 septs, and the large types are always twice this size. .P -As for operators, '?' is always SUBTRACT WITHOUT BORROW, and '^' -is always ADD WITHOUT CARRY. 'V' is the OR operation and always -returns the max of its inputs. '&' is the AND operation, which chooses -0 if possible but otherwise returns the max of the inputs. '@' is BUT, +As for operators, ? is always SUBTRACT WITHOUT BORROW, and ^ +is always ADD WITHOUT CARRY. V is the OR operation and always +returns the max of its inputs. & is the AND operation, which chooses +0 if possible but otherwise returns the max of the inputs. @ is BUT, which prefers 1, then 0, then the max of the remaining possibilities. Rather than add more special symbols forever, a numeric modifier may -be placed directly before the '@' symbol to indicate the operation -that prefers one of the digits not already represented. Thus in files -ending in '.5i', the permitted unary operators are '?', '^', '&', '@', -\&'2@', '3@', and 'V'. Use of such barbarisms as '0@' to represent '&' -are not permitted, nor is the use of '@' or '^' in files with either -of the extensions '.i' or '.2i'. Why not? You just can't, that's why. +be placed directly before the @ to indicate the operation +that prefers one of the digits not already represented. Thus in files +ending in '.5i', the permitted unary operators are ?, ^, &, @, 2@, 3@, +and V. Use of such barbarisms as 0@ to represent & +are not permitted, nor is the use of @ or ^ in files with either +of the extensions '.i' or '.2i'. Why not? You just can't, that's why. Don't ask so many questions. .P As a closing example, we note that in balanced quinary notation, @@ -1842,6 +1953,24 @@ by 4, modulo 5. .P Now go beat your head against the wall for a while.\} .H 1 "SUBROUTINE LIBRARY" +.if '\*c'y' \{\ +.DS I F +"You don't know what you're talking about!" cried Humpty Dumpty. "How +many days are there in a year?" +.P +"Three hundred and sixty-five," said Alice. +.P +"And how many birthdays have you?" +.P +"One." +.P +"And if you take one from three hundred and sixty-five, what remains?" +.P +"Three hundred and sixty-four, of course." +.P +Humpty Dumpty looked doubtful. "I'd rather see that done on paper," he +said. +.DE \} .SETR sublib .P INTERCAL provides several built-in subroutines to which control can be @@ -1852,14 +1981,14 @@ addition, subtraction, etc. .P In general, the operands are .1, .2, etc., or :1, :2, etc., and the result(s) are stored in what would have been the next operand(s). For instance, one -routine adds .1 to .2 and store the sum in .3, with .4 being used to indicate +routine adds .1 to .2 and stores the sum in .3, with .4 being used to indicate overflow. All variables not used for results are left unchanged. .H 2 "Available Functions" .SETR functions .P At the time of this writing, only the most fundamental operations are offered in the library, as a more complete selection would require prohibitive time -and coree to implement. These functions, along with their corresponding entry +and core to implement. These functions, along with their corresponding entry points (entered via DO (entry) NEXT) are listed below. .DS L .cs R 24 @@ -1875,10 +2004,6 @@ points (entered via DO (entry) NEXT) are listed below. .3 <- #0 if .2 is #0 (1050) .2 <- :1 divided by .1, error exit on overflow .2 <- #0 if .1 is #0 -.if '\*c'y' \{\ - (1060) .3 <- logical or of .1 and .2 - (1070) .3 <- logical and of .1 and .2 - (1080) .3 <- logical xor of .1 and .2 \} (1500) :3 <- :1 plus :2, error exit on overflow (1509) :3 <- :1 plus :2 @@ -1906,9 +2031,23 @@ points (entered via DO (entry) NEXT) are listed below. .P The C-INTERCAL compiler will automatically include the system library if a DO (1xxx) NEXT statement is used, and if no (1xxx) labels are defined anywhere, -where (1xxx) is a label in the 1000-1999 range, inclusive. This was not +where (1xxx) is a label in the 1000-1999 range, inclusive. This was not an INTERCAL-72 feature. \} .H 1 "PROGRAMMING HINTS" +.if '\*c'y' \{\ +.DS I F +"If any one of them can explain it," said Alice, "I'll give him +sixpence. \fII\fR don't believe there's an atom of meaning in it." +The jury all wrote down, on their slates, "\fIShe\fR doesn't +believe there's an atom of meaning in it," but none of them attempted +to explain the paper. +.P +"If there's no meaning in it," said the King, "that saves a world of +trouble, you know, as we needn't try to find any. And yet, I don't +know," he went on, spreading out the verses on one knee, and looking +at them with one eye: "I seem to see some meaning in them, after +all...." +.DE \} .SETR proghints .P For the user looking to become more familiar with the INTERCAL language, we @@ -1921,7 +2060,12 @@ for instructive analysis. Since there was only one such program available, we have proceeded to use it. It is known as the "INTERCAL System Library." .H 2 "Description" .P -The program listing begins on the second page following. It is in the same +.\" CORRECTION: +.\" "is in section {section}" was "on the second page following" +.\" We can't rely on the page breaks any more. +The program listing is in section +.GETHN syslib +\&. It is in the same format as would be produced by the Princeton INTERCAL compiler in FORMAT mode with WIDTH=62 (see section .GETHN princeton @@ -1947,8 +2091,15 @@ to #2 and leave #1 alone) use "\*(vb'exp'\*(ct#2"~#3. Certain conditions are easily checked. For example, to test for zero, select the value from itself and select the bottom bit (see statement 54). To test for all bits being 1's, select the value from itself and select the -top bit (see statement 261). The test for greater than, performed in -statements 192 and 193 on 32-bit values, employs binary logical operations, +top bit. +.\" CORRECTION: +.\" "statements 219 and 220" were "statement 192 and 193", but there +.\" is no such test there. +.\" Also, last sentence had parenthetical "(see statement 261)". Not +.\" only does 261 contain no such test, the library as a whole doesn't +.\" seem to either. +The test for greater than, performed in +statements 219 and 220 on 32-bit values, employs binary logical operations, which are performed as follows: .DS \&'\*(vb.1\*(ct.2'~'#0\*(ct#65535' @@ -1964,7 +2115,7 @@ for 16-bit values or, for 32-bit values: Testing for greater-than with 16-bit values is somewhat simpler and is done with the pair of statements: .DS L - DO .C <- '\*(vb.Ac.B'~'#0\*(ct#65535' + DO .C <- '\*(vb.A\*(ct.B'~'#0\*(ct#65535' DO .C <- '&"'.A~.C'~'"\*(vb'\*(vb.C~.C'\*(ct#32768" ~"#0\*(ct#65535"'"\*(ct".C~.C"'~#1 .DE @@ -1989,303 +2140,310 @@ shifting 16- and 32-bit variables logically one place to the left. Statement 231 demonstrates right-shifting for 32-bit variables. .bp .H 2 "Program Listing" +.SETR syslib .DS L .cs R 24 - 1 (1000) PLEASE IGNORE .4 - 2 PLEASE ABSTAIN FROM (1005) - 3 (1009) DO STASH .1 + .2 + .5 + .6 - 4 DO .4 <- #1 - 5 DO (1004) NEXT - 6 (1004) PLEASE FORGET #1 - 7 DO .3 <- '\*(vb.1\*(ct.2'~'#0\*(ct#65535' - 8 DO .6 <- '&.1\*(ct.2'~'#0\*(ct#65535' - 9 PLEASE DO .5 <- "\*(vb!6~#32768'\*(ct#1"~#3 - 10 DO (1002) NEXT - 11 DO .4 <- #2 - 12 (1005) DO (1006) NEXT -* 13 (1999) DOUBLE OR SINGLE PRECISION OVERFLOW - 14 (1002) DO (1001) NEXT - 15 (1006) PLEASE FORGET #1 - 16 DO .5 <- '\*(vb"!6~.6'~#1"\*(ct#1'~#3 - 17 DO (1003) NEXT - 18 DO .1 <- .3 - 19 DO .2 <- !6\*(ct#0'~'#32767\*(ct#1' - 20 DO (1004) NEXT - 21 (1003) DO (1001) NEXT - 22 DO REINSTATE (1005) - 23 (1007) PLEASE RETRIEVE .1 + .2 + .5 + .6 - 24 DO REMEMBER .4 - 25 PLEASE RESUME #2 - 26 (1001) DO RESUME .5 - 27 (1010) DO STASH .1 + .2 + .4 - 28 DO .4 <- .1 - 29 DO .1 <- '\*(vb.2\*(ct#65535'~'#0\*(ct#65535' - 30 DO (1020) NEXT - 31 PLEASE DO .2 <- .4 - 32 PLEASE DO (1009) NEXT - 33 DO RETRIEVE .1 + .2 + .4 - 34 PLEASE RESUME #1 - 35 (1020) DO STASH .2 + .3 - 36 DO .2 <- #1 - 37 PLEASE DO (1021) NEXT - 38 (1021) DO FORGET #1 - 39 DO .3 <- "\*(vb!1~.2'\*(ct#1"~#3 - 40 PLEASE DO .1 <- '\*(vb.1\*(ct.2'~'#0\*(ct#65535' - 41 DO (1022) NEXT - 42 DO .2 <- !2\*(ct#0'~'#32767\*(ct#1' - 43 DO (1021) NEXT - 44 (1023) PLEASE RESUME .3 - 45 (1022) DO (1023) NEXT - 46 PLEASE RETRIEVE .2 + .3 - 47 PLEASE RESUME #2 - 48 (1030) DO ABSTAIN FROM (1033) - 49 PLEASE ABSTAIN FROM (1032) - 50 (1039) DO STASH :1 + .5 - 51 DO (1530) NEXT - 52 DO .3 <- :1~#65535 - 53 PLEASE DO .5 <- :1~'#65280\*(ct#65280' - 54 DO .5 <- '\*(vb"!5~.5'~#1"\*(ct#1'~#3 - 55 DO (1031) NEXT - 56 (1032) DO (1033) NEXT - 57 DO (1999) NEXT - 58 (1031) DO (1001) NEXT - 59 (1033) DO .4 <- .5 - 60 DO REINSTATE (1032) - 61 PLEASE REINSTATE (1033) - 62 DO RETRIEVE :1 + .5 - 63 PLEASE RESUME #2 - 64 (1040) PLEASE STASH .1 + .2 + .2 + :1 + :2 + :3 - 65 DO .2 <- #0 - 66 DO (1520) NEXT - 67 DO STASH :1 - 68 PLEASE RETRIEVE .2 - 69 DO .1 <- .2 - 70 DO .2 <- #0 - 71 PLEASE DO (1520) NEXT - 72 DO :2 <- :1 - 73 DO RETRIEVE .1 + .2 + :1 - 74 DO (1550) NEXT - 75 PLEASE DO .3 <- :3 - 76 DO RETRIEVE :1 + :2 + :3 - 77 DO RESUME #1 - 78 (1050) PLEASE STASH :2 + :3 + .5 - 79 DO :2 <- .1 - 80 PLEASE DO (1550) NEXT - 81 DO .5 <- :3~'#65280\*(ct#65280' - 82 DO .5 <- '\*(vb"!5~.5'~#1"\*(ct#1'~#3 - 83 DO (1051) NEXT - 84 DO (1999) NEXT - 85 (1051) DO (1001) NEXT - 86 DO .2 <- :3 - 87 PLEASE RETRIEVE :2 + :3 + .5 - 88 DO RESUME #2 - 89 (1500) PLEASE ABSTAIN FROM (1502) - 90 PLEASE ABSTAIN FROM (1506) - 91 (1509) PLEASE STASH :1 + .1 + .2 + .3 + .4 + .5 + .6 - 92 DO .1 <- :1~#65535 - 93 PLEASE DO .2 <- :2~#65535 - 94 DO (1009) NEXT - 95 DO .5 <- .3 - 96 PLEASE DO .6 <- .4 - 97 DO .1 <- :1~'#65280\*(ct#65280' - 98 DO .2 <- :2~'#65280\*(ct#65280' - 99 DO (1009) NEXT - 100 DO .1 <- .3 - 101 PLEASE DO (1503) NEXT - 102 DO .6 <- .4 - 103 DO .2 <- #1 - 104 DO (1009) NEXT - 105 DO .1 <- .3 - 106 DO (1501) NEXT - 107 (1504) PLEASE RESUME .6 - 108 (1503) DO (1504) NEXT - 109 (1501) DO .2 <- .5 - 110 DO .5 <- '\*(vb"'&.6\*(ct.4'~#1"\*(ct#2'~#3 - 111 DO (1505) NEXT - 112 (1506) DO (1502) NEXT - 113 PLEASE DO (1999) NEXT - 114 (1505) DO (1001) NEXT - 115 (1502) DO :4 <- .5 - 116 DO (1520) NEXT - 117 DO :3 <- :1 - 118 PLEASE RETRIEVE :1 + .1 + .2 + .3 + .4 + .5 + .6 - 119 DO REINSTATE (1502) - 120 DO REINSTATE (1506) - 121 PLEASE RESUME #3 - 122 (1510) DO STASH :1 + :2 + :4 - 123 DO :1 <- "'\*(vb":2~'#65535\*(ct#0'"\*(ct#65535'~'#0\*(ct#6553 - 5'"\*(ct"'\*(vb":2~'#0\*(ct#65535'"\*(ct#65535'~'#0\*(ct#65535 - '" - 124 DO :2 <- #1 - 125 DO (1509) NEXT - 126 PLEASE RETRIEVE :1 - 127 DO :2 <- :3 - 128 PLEASE DO (1509) NEXT - 129 DO RETRIEVE :2 + :4 - 130 PLEASE RESUME #1 - 131 (1520) PLEASE STASH .3 + .4 - 132 DO .3 <- .1~#43690 - 133 DO (1525) NEXT - 134 PLEASE DO .4 <- 'V.3\*(ct".2~#43690"'~'#0\*(ct#65535' - 135 DO .3 <- .1~#21845 - 136 PLEASE DO (1525) NEXT - 137 DO :1 <- .4\*(ct"'V.3\*(ct".2~#21845"'~'#0\*(ct#65535'" - 138 PLEASE RETRIEVE .3 + .4 - 139 DO RESUME #1 - 140 (1525) DO .3 <- '"'"'"!3\*(ct#0'~'#32767\*(ct#1'"\*(ct#0'~'#32767 - \*(ct#1'"\*(ct#0'~'#16383\*(ct#3'"\*(ct#0'~'#4095\*(ct#15' - 141 PLEASE RESUME #1 - 142 (1530) DO STASH :2 + :3 + .3 + .5 - 143 DO :1 <- #0 - 144 DO :2 <- .2 - 145 DO .3 <- #1 - 146 DO (1535) NEXT - 147 (1535) PLEASE FORGET #1 - 148 DO .5 <- "\*(vb!1~.3'\*(ct#1"~#3 - 149 DO (1531) NEXT - 150 DO (1500) NEXT - 151 DO :1 <- :3 - 152 PLEASE DO (1533) NEXT - 153 (1531) PLEASE DO (1001) NEXT - 154 (1533) DO FORGET #1 - 155 DO .3 <- !3\*(ct#0'~'#32767\*(ct#1' - 156 DO :2 <- ":2~'#0\*(ct#65535'"\*(ct"'":2~'#32767\*(ct#0'"\*(ct# - 0'~'#32767\*(ct#1'" - 157 PLEASE DO .5 <- "\*(vb!3~.3'\*(ct#1"~#3 - 158 DO (1532) NEXT - 159 DO (1535) NEXT - 160 (1532) DO (1001) NEXT - 161 PLEASE RETRIEVE :2 + :3 + .3 + .5 - 162 DO RESUME #2 - 163 (1540) PLEASE ABSTAIN FROM (1541) - 164 DO ABSTAIN FROM (1542) - 165 (1549) PLEASE STASH :1 + :2 + :4 + :5 + .1 + .2 + .5 - 166 DO .1 <- :1~#65535 - 167 PLEASE DO .2 <- :2~'#65280\*(ct#65280' - 168 DO .5 <- :1~'#65280\*(ct#65280' - 169 DO (1530) NEXT - 170 DO :3 <- :1 - 171 DO .2 <- :2~#65535 - 172 PLEASE DO (1530) NEXT - 173 DO :5 <- :1 - 174 DO .1 <- .5 - 175 DO (1530) NEXT - 176 DO :4 <- :1 - 177 PLEASE DO :1 <- ":3~'#65280\*(ct#65280'"\*(ct":5~'#652 - 80\*(ct#65280'" - 178 DO .5 <- ':1~:1'~#1 - 179 DO .2 <- :2~'#65280\*(ct#65280' - 180 DO (1530) NEXT - 181 PLEASE DO .5 <- '"':1~:1'~#1"\*(ct.5'~#3 - 182 DO .1 <- :3~#65535 - 183 DO .2 <- #0 - 184 DO (1520) NEXT - 185 PLEASE DO :2 <- :1 - 186 PLEASE DO .1 <- :4~#65535 - 187 DO (1520) NEXT - 188 DO (1509) NEXT - 189 DO .5 <- !5\*(ct":4~#3"'~#15 - 190 DO :1 <- :3 - 191 DO :2 <- :5 - 192 DO (1509) NEXT - 193 PLEASE DO .5 <- !5\*(ct":4~#3"'~#63 - 194 DO .5 <- '\*(vb"!5~.5'~#1"\*(ct#1'~#3 - 195 PLEASE RETRIEVE :4 - 196 (1541) DO :4 <- .5 - 197 DO (1543) NEXT - 198 (1542) DO (1544) NEXT - 199 PLEASE DO (1999) NEXT - 200 (1543) DO (1001) NEXT - 201 (1544) DO REINSTATE (1541) - 202 PLEASE REINSTATE (1542) - 203 PLEASE RETRIEVE :1 + :2 + :5 + .1 + .2 + .5 - 204 DO RESUME #2 - 205 (1550) DO STASH :1 + :4 + :5 + .5 - 206 DO :3 <- #0 - 207 DO .5 <- '\*(vb"':2~:2'~#1"\*(ct#1'~#3 - 208 PLEASE DO (1551) NEXT - 209 DO :4 <- #1 - 210 PLEASE DO (1553) NEXT - 211 (1553) DO FORGET #1 - 212 DO .5 <- '\*(vb":2~'#32768\*(ct#0'"\*(ct#2'~#3 - 213 DO (1552) NEXT - 214 DO :2 <- ":2~'#0\*(ct#65535'"\*(ct"'":2~'#32767\*(ct#0'"\*(ct# - 0'~'#32767\*(ct#1'" - 215 PLEASE DO :4 <- ":4~'#0\*(ct#65535'"\*(ct"'":4~'#32767 - \*(ct#0'"\*(ct#0'~'#32767\*(ct#1'" - 216 DO (1553) NEXT - 217 (1552) DO (1001) NEXT - 218 (1556) PLEASE FORGET #1 - 219 DO :5 <- "'\*(vb":1~'#65535\*(ct#0'"\*(ct":2~'#65535\*(ct#0'"' - ~'#0\*(ct#65535'"\*(ct"'\*(vb":1~'#0\*(ct#65535'"\*(ct":2~'#0\*(ct - #65535'"'~'#0\*(ct#65535'" - 220 DO .5 <- '\*(vb"'&"':2~:5'~'"'\*(vb"'\*(vb":5~:5"~"#65535~ - #65535"'~'#65535\*(ct#0'"\*(ct#32768'~'#0\*(ct#65535'" - \*(ct"'\*(vb":5~:5"~"#65535\*(ct#65535"'~'#0\*(ct#65535'"' - "\*(ct"':5~:5'~#1"'~#1"\*(ct#2'~#3 - 221 DO (1554) NEXT - 222 DO :5 <- :3 - 223 DO (1510) NEXT - 224 PLEASE DO :1 <- :3 - 225 DO :3 <- "'V":4~'#65535\*(ct#0'"\*(ct":5~'#65535\*(ct#0'"' - ~'#0\*(ct#65535'"\*(ct"'V":4~'#0\*(ct#65535'"\*(ct":5~'#0\*(ct - #65535'"'~'#0\*(ct#65535'" - 226 DO (1555) NEXT - 227 (1554) PLEASE DO (1001) NEXT - 228 (1555) DO FORGET #1 - 229 DO .5 <- "\*(vb':4~#1'\*(ct#2"~#3 - 230 DO (1551) NEXT - 231 DO :2 <- ":2~'#0\*(ct#65534'"\*(ct":2~'#65535\*(ct#0'" - 232 DO :4 <- ":4~'#0\*(ct#65534'"\*(ct":4~'#65535\*(ct#0'" - 233 PLEASE DO (1556) NEXT - 234 (1551) DO (1001) NEXT - 235 PLEASE RETRIEVE :1 + :4 + :5 + .5 - 236 PLEASE RESUME #2 - 237 (1900) DO STASH .2 + .3 + .5 - 238 DO .1 <- #0 - 239 DO .2 <- #1 - 240 PLEASE DO (1901) NEXT - 241 (1901) DO FORGET #1 - 242 DO %50 .1 <- 'V.1\*(ct.2'~'#0\*(ct#65535' - 243 DO .2 <- !2\*(ct#0'~'#32767\*(ct#1' - 244 PLEASE DO .5 <- "\*(vb!2~.2'\*(ct#1"~#3 - 245 DO (1902) NEXT - 246 DO (1901) NEXT - 247 (1902) DO (1001) NEXT - 248 DO RETRIEVE .2 + .3 + .5 - 249 PLEASE RESUME #2 - 250 (1910) PLEASE STASH .1 + .3 + .5 + :1 + :2 + :3 - 251 DO .3 <- #65524 - 252 DO :1 <- #6 - 253 DO (1911) NEXT -* 254 PLEASE NOTE THAT YOU CAN'T GET THERE FROM HERE - 255 (1912) DO (1001) NEXT - 256 (1911) DO FORGET #1 - 257 PLEASE DO (1900) NEXT - 258 DO :2 <- .1 - 259 DO (1500) NEXT - 260 PLEASE DO :1 <- :3 - 261 DO .1 <- .3 - 262 DO (1020) NEXT - 263 PLEASE DO .3 <- .1 - 264 DO .5 <- '\*(vb"!3~.3'~#1"\*(ct#2'~#3 - 265 DO (1912) NEXT - 266 DO .1 <- #12 - 267 PLEASE DO (1050) NEXT - 268 DO RETRIEVE .1 - 269 DO (1530) NEXT - 270 DO :2 <- #32768 - 271 DO (1500) NEXT - 272 PLEASE DO .2 <- :3~'#65280\*(ct#65280' - 273 PLEASE RETRIEVE .3 + .5 + :1 + :2 + :3 - 274 DO RESUME #1 -.if '\*c'y' \{\ - 275 (1060) DO .3<-'V".1\*(ct.2"'~'#0\*(ct#65535' - 276 DO RESUME #1 - 277 (1070) DO .3<-'&".1\*(ct.2"'~'#0\*(ct#65535' - 278 DO RESUME #1 - 279 (1080) DO .3<-'\*(vb".1\*(ct.2"'~'#0\*(ct#65535' \} - 280 DO RESUME #1 +.\" CORRECTION: +.\" This is the corrected system library, not the rather buggy original. +.\" Can be semi-mechanically generated from the syslib.i file with +.\" sed syslib.i -e 1d -e '/\$/s//\\*(ct/g' -e '/?/s//\\*(vb/g' | nl | expand + \" but you have to +.\" (a) restore the splat on line 13 DOUBLE OR SINGLE PRECISION OVERFLOW +.\" (b) restore the splat on line 254 PLEASE NOTE .... +.\" (c) appropriately conditionalize lines 289-294 +.\" (d) manually break lines where they wrap + 1 (1000) PLEASE IGNORE .4 + 2 PLEASE ABSTAIN FROM (1005) + 3 (1009) DO STASH .1 + .2 + .5 + .6 + 4 DO .4 <- #1 + 5 DO (1004) NEXT + 6 (1004) PLEASE FORGET #1 + 7 DO .3 <- '\*(vb.1\*(ct.2'~'#0\*(ct#65535' + 8 DO .6 <- '&.1\*(ct.2'~'#0\*(ct#65535' + 9 PLEASE DO .5 <- "\*(vb!6~#32768'\*(ct#1"~#3 + 10 DO (1002) NEXT + 11 DO .4 <- #2 + 12 (1005) DO (1006) NEXT +* 13 (1999) DOUBLE OR SINGLE PRECISION OVERFLOW + 14 (1002) DO (1001) NEXT + 15 (1006) PLEASE FORGET #1 + 16 DO .5 <- '\*(vb"!6~.6'~#1"\*(ct#1'~#3 + 17 DO (1003) NEXT + 18 DO .1 <- .3 + 19 DO .2 <- !6\*(ct#0'~'#32767\*(ct#1' + 20 DO (1004) NEXT + 21 (1003) DO (1001) NEXT + 22 DO REINSTATE (1005) + 23 (1007) PLEASE RETRIEVE .1 + .2 + .5 + .6 + 24 DO REMEMBER .4 + 25 PLEASE RESUME #2 + 26 (1001) DO RESUME .5 + 27 (1010) DO STASH .1 + .2 + .4 + 28 DO .4 <- .1 + 29 DO .1 <- '\*(vb.2\*(ct#65535'~'#0\*(ct#65535' + 30 DO (1020) NEXT + 31 PLEASE DO .2 <- .4 + 32 PLEASE DO (1009) NEXT + 33 DO RETRIEVE .1 + .2 + .4 + 34 PLEASE RESUME #1 + 35 (1020) DO STASH .2 + .3 + 36 DO .2 <- #1 + 37 PLEASE DO (1021) NEXT + 38 (1021) DO FORGET #1 + 39 DO .3 <- "\*(vb!1~.2'\*(ct#1"~#3 + 40 PLEASE DO .1 <- '\*(vb.1\*(ct.2'~'#0\*(ct#65535' + 41 DO (1022) NEXT + 42 DO .2 <- !2\*(ct#0'~'#32767\*(ct#1' + 43 DO (1021) NEXT + 44 (1023) PLEASE RESUME .3 + 45 (1022) DO (1023) NEXT + 46 PLEASE RETRIEVE .2 + .3 + 47 PLEASE RESUME #2 + 48 (1030) DO ABSTAIN FROM (1033) + 49 PLEASE ABSTAIN FROM (1032) + 50 (1039) DO STASH :1 + .5 + 51 DO (1530) NEXT + 52 DO .3 <- :1~#65535 + 53 PLEASE DO .5 <- :1~'#65280\*(ct#65280' + 54 DO .5 <- '\*(vb"!5~.5'~#1"\*(ct#1'~#3 + 55 DO (1031) NEXT + 56 (1032) DO (1033) NEXT + 57 DO (1999) NEXT + 58 (1031) DO (1001) NEXT + 59 (1033) DO .4 <- .5 + 60 DO REINSTATE (1032) + 61 PLEASE REINSTATE (1033) + 62 DO RETRIEVE :1 + .5 + 63 PLEASE RESUME #2 + 64 (1040) PLEASE STASH .1 + .2 + .2 + :1 + :2 + :3 + 65 DO .2 <- #0 + 66 DO (1520) NEXT + 67 DO STASH :1 + 68 PLEASE RETRIEVE .2 + 69 DO .1 <- .2 + 70 DO .2 <- #0 + 71 PLEASE DO (1520) NEXT + 72 DO :2 <- :1 + 73 DO RETRIEVE .1 + .2 + :1 + 74 DO (1550) NEXT + 75 PLEASE DO .3 <- :3 + 76 DO RETRIEVE :1 + :2 + :3 + 77 DO RESUME #1 + 78 (1050) PLEASE STASH :2 + :3 + .5 + 79 DO :2 <- .1 + 80 PLEASE DO (1550) NEXT + 81 DO .5 <- :3~'#65280\*(ct#65280' + 82 DO .5 <- '\*(vb"!5~.5'~#1"\*(ct#1'~#3 + 83 DO (1051) NEXT + 84 DO (1999) NEXT + 85 (1051) DO (1001) NEXT + 86 DO .2 <- :3 + 87 PLEASE RETRIEVE :2 + :3 + .5 + 88 DO RESUME #2 + 89 (1500) PLEASE ABSTAIN FROM (1502) + 90 PLEASE ABSTAIN FROM (1506) + 91 (1509) PLEASE STASH :1 + .1 + .2 + .3 + .4 + .5 + .6 + 92 DO .1 <- :1~#65535 + 93 PLEASE DO .2 <- :2~#65535 + 94 DO (1009) NEXT + 95 DO .5 <- .3 + 96 PLEASE DO .6 <- .4 + 97 DO .1 <- :1~'#65280\*(ct#65280' + 98 DO .2 <- :2~'#65280\*(ct#65280' + 99 DO (1009) NEXT + 100 DO .1 <- .3 + 101 PLEASE DO (1503) NEXT + 102 DO .6 <- .4 + 103 DO .2 <- #1 + 104 DO (1009) NEXT + 105 DO .1 <- .3 + 106 DO (1501) NEXT + 107 (1504) PLEASE RESUME .6 + 108 (1503) DO (1504) NEXT + 109 (1501) DO .2 <- .5 + 110 DO .5 <- '\*(vb"'&.6\*(ct.4'~#1"\*(ct#2'~#3 + 111 DO (1505) NEXT + 112 (1506) DO (1502) NEXT + 113 PLEASE DO (1999) NEXT + 114 (1505) DO (1001) NEXT + 115 (1502) DO :4 <- .5 + 116 DO (1520) NEXT + 117 DO :3 <- :1 + 118 PLEASE RETRIEVE :1 + .1 + .2 + .3 + .4 + .5 + .6 + 119 DO REINSTATE (1502) + 120 DO REINSTATE (1506) + 121 PLEASE RESUME #3 + 122 (1510) DO STASH :1 + :2 + :4 + 123 DO :1 <- "'\*(vb":2~'#65535\*(ct#0'"\*(ct#65535' + ~'#0\*(ct#65535'"\*(ct"'\*(vb":2~'#0\*(ct#65535' + "\*(ct#65535'~'#0\*(ct#65535'" + 124 DO :2 <- #1 + 125 DO (1509) NEXT + 126 PLEASE RETRIEVE :1 + 127 DO :2 <- :3 + 128 PLEASE DO (1509) NEXT + 129 DO RETRIEVE :2 + :4 + 130 PLEASE RESUME #1 + 131 (1520) PLEASE STASH .3 + .4 + 132 DO .3 <- .1~#43690 + 133 DO (1525) NEXT + 134 PLEASE DO .4 <- 'V.3\*(ct".2~#43690"'~'#0\*(ct#65535' + 135 DO .3 <- .1~#21845 + 136 PLEASE DO (1525) NEXT + 137 DO :1 <- .4\*(ct"'V.3\*(ct".2~#21845"'~'#0\*(ct#65535'" + 138 PLEASE RETRIEVE .3 + .4 + 139 DO RESUME #1 + 140 (1525) DO .3 <- '"'"'"!3\*(ct#0'~'#32767\*(ct#1'"\*(ct#0' + ~'#32767\*(ct#1'"\*(ct#0'~'#16383\*(ct#3'"\*(ct#0' + ~'#4095\*(ct#15' + 141 PLEASE RESUME #1 + 142 (1530) DO STASH :2 + :3 + .3 + .5 + 143 DO :1 <- #0 + 144 DO :2 <- .2 + 145 DO .3 <- #1 + 146 DO (1535) NEXT + 147 (1535) PLEASE FORGET #1 + 148 DO .5 <- "\*(vb!1~.3'\*(ct#1"~#3 + 149 DO (1531) NEXT + 150 DO (1500) NEXT + 151 DO :1 <- :3 + 152 PLEASE DO (1533) NEXT + 153 (1531) PLEASE DO (1001) NEXT + 154 (1533) DO FORGET #1 + 155 DO .3 <- !3\*(ct#0'~'#32767\*(ct#1' + 156 DO :2 <- ":2~'#0\*(ct#65535'"\*(ct"'":2~'#32767 + \*(ct#0'"\*(ct#0'~'#32767\*(ct#1'" + 157 PLEASE DO .5 <- "\*(vb!3~.3'\*(ct#1"~#3 + 158 DO (1532) NEXT + 159 DO (1535) NEXT + 160 (1532) DO (1001) NEXT + 161 PLEASE RETRIEVE :2 + :3 + .3 + .5 + 162 DO RESUME #2 + 163 (1540) PLEASE ABSTAIN FROM (1541) + 164 DO ABSTAIN FROM (1542) + 165 (1549) PLEASE STASH :1 + :2 + :4 + :5 + .1 + .2 + .5 + 166 DO .1 <- :1~#65535 + 167 PLEASE DO .2 <- :2~'#65280\*(ct#65280' + 168 DO .5 <- :1~'#65280\*(ct#65280' + 169 DO (1530) NEXT + 170 DO :3 <- :1 + 171 DO .2 <- :2~#65535 + 172 PLEASE DO (1530) NEXT + 173 DO :5 <- :1 + 174 DO .1 <- .5 + 175 DO (1530) NEXT + 176 DO :4 <- :1 + 177 PLEASE DO :1 <- ":3~'#65280\*(ct#65280'" + \*(ct":4~'#65280\*(ct#65280'" + 178 DO .5 <- ':1~:1'~#1 + 179 DO .2 <- :2~'#65280\*(ct#65280' + 180 DO (1530) NEXT + 181 PLEASE DO .5 <- '"':1~:1'~#1"\*(ct.5'~#3 + 182 DO .1 <- :3~#65535 + 183 DO .2 <- #0 + 184 DO (1520) NEXT + 185 PLEASE DO :2 <- :1 + 186 PLEASE DO .1 <- :4~#65535 + 187 DO (1520) NEXT + 188 DO (1509) NEXT + 189 DO .5 <- !5\*(ct":4~#3"'~#15 + 190 DO :1 <- :3 + 191 DO :2 <- :5 + 192 DO (1509) NEXT + 193 PLEASE DO .5 <- !5\*(ct":4~#3"'~#172 + 194 DO .5 <- '\*(vb"!5~.5'~#1"\*(ct#1'~#3 + 195 PLEASE RETRIEVE :4 + 196 (1541) DO :4 <- .5 + 197 DO (1543) NEXT + 198 (1542) DO (1544) NEXT + 199 PLEASE DO (1999) NEXT + 200 (1543) DO (1001) NEXT + 201 (1544) DO REINSTATE (1541) + 202 PLEASE REINSTATE (1542) + 203 PLEASE RETRIEVE :1 + :2 + :5 + .1 + .2 + .5 + 204 DO RESUME #2 + 205 (1550) DO STASH :1 + :4 + :5 + .5 + 206 DO :3 <- #0 + 207 DO .5 <- '\*(vb"':2~:2'~#1"\*(ct#1'~#3 + 208 PLEASE DO (1551) NEXT + 209 DO :4 <- #1 + 210 PLEASE DO (1553) NEXT + 211 (1553) DO FORGET #1 + 212 DO .5 <- '\*(vb":2~'#32768\*(ct#0'"\*(ct#2'~#3 + 213 DO (1552) NEXT + 214 DO :2 <- ":2~'#0\*(ct#65535'"\*(ct"'":2~'#32767 + \*(ct#0'"\*(ct#0'~'#32767\*(ct#1'" + 215 PLEASE DO :4 <- ":4~'#0\*(ct#65535'"\*(ct"'":4 + ~'#32767\*(ct#0'"\*(ct#0'~'#32767\*(ct#1'" + 216 DO (1553) NEXT + 217 (1552) DO (1001) NEXT + 218 (1556) PLEASE FORGET #1 + 219 DO :5 <- "'\*(vb":1~'#65535\*(ct#0'"\*(ct":2 + ~'#65535\*(ct#0'"'~'#0\*(ct#65535'"\*(ct"' + \*(vb":1~'#0\*(ct#65535'"\*(ct":2~'#0\*(ct + #65535'"'~'#0\*(ct#65535'" + 220 DO .5 <- '\*(vb"'&"':2~:5'~'"'\*(vb"'\*(vb":5~:5 + "~"#65535\*(ct#65535"'~'#65535\*(ct#0'"\*(ct + #32768'~'#0\*(ct#65535'"\*(ct"'\*(vb":5~:5" + ~"#65535\*(ct#65535"'~'#0\*(ct#65535'"'"\*(ct"' + :5~:5'~#1"'~#1"\*(ct#2'~#3 + 221 DO (1554) NEXT + 222 DO :5 <- :3 + 223 DO (1510) NEXT + 224 PLEASE DO :1 <- :3 + 225 DO :3 <- "'V":4~'#65535\*(ct#0'"\*(ct":5~'#65535 + \*(ct#0'"'~'#0\*(ct#65535'"\*(ct"'V":4~'#0 + \*(ct#65535'"\*(ct":5~'#0\*(ct#65535'"'~'#0 + \*(ct#65535'" + 226 DO (1555) NEXT + 227 (1554) PLEASE DO (1001) NEXT + 228 (1555) DO FORGET #1 + 229 DO .5 <- "\*(vb':4~#1'\*(ct#2"~#3 + 230 DO (1551) NEXT + 231 DO :2 <- ":2~'#0\*(ct#65534'"\*(ct":2~'#65535\*(ct#0'" + 232 DO :4 <- ":4~'#0\*(ct#65534'"\*(ct":4~'#65535\*(ct#0'" + 233 PLEASE DO (1556) NEXT + 234 (1551) DO (1001) NEXT + 235 PLEASE RETRIEVE :1 + :4 + :5 + .5 + 236 PLEASE RESUME #2 + 237 (1900) DO STASH .2 + .3 + .5 + 238 DO .1 <- #0 + 239 DO .2 <- #1 + 240 PLEASE DO (1901) NEXT + 241 (1901) DO FORGET #1 + 242 DO %50 .1 <- 'V.1\*(ct.2'~'#0\*(ct#65535' + 243 DO .2 <- !2\*(ct#0'~'#32767\*(ct#1' + 244 PLEASE DO .5 <- "\*(vb!2~.2'\*(ct#1"~#3 + 245 DO (1902) NEXT + 246 DO (1901) NEXT + 247 (1902) DO (1001) NEXT + 248 DO RETRIEVE .2 + .3 + .5 + 249 PLEASE RESUME #2 + 250 (1910) PLEASE STASH .1 + .3 + .5 + :1 + :2 + :3 + 251 DO .3 <- #65524 + 252 DO :1 <- #6 + 253 DO (1911) NEXT +* 254 PLEASE NOTE THAT YOU CAN'T GET THERE FROM HERE + 255 (1912) DO (1001) NEXT + 256 (1911) DO FORGET #1 + 257 PLEASE DO (1900) NEXT + 258 DO :2 <- .1 + 259 DO (1500) NEXT + 260 PLEASE DO :1 <- :3 + 261 DO .1 <- .3 + 262 DO (1020) NEXT + 263 PLEASE DO .3 <- .1 + 264 DO .5 <- '\*(vb"!3~.3'~#1"\*(ct#2'~#3 + 265 DO (1912) NEXT + 266 DO .1 <- #12 + 267 PLEASE DO (1050) NEXT + 268 DO RETRIEVE .1 + 269 DO (1530) NEXT + 270 DO :2 <- #32768 + 271 DO (1500) NEXT + 272 PLEASE DO .2 <- :3~'#65280\*(ct#65280' + 273 PLEASE RETRIEVE .3 + .5 + :1 + :2 + :3 + 274 DO RESUME #1 .cs R .DE .bp @@ -2314,12 +2472,16 @@ the writing of the floating-point library as well as sine and cosine functions. Calculate, to :1 places, the value of pi. .if '\*c'y' \{\ .P -(The first three and last one of the preceding suggested projects from -the INTERCAL-72 manual are included in the C-INTERCAL distribution's -pit directory of sample code. The floating-point library and FFT -routine remain as worthy challenges...) \} +(Working programs for each of these projects are included in the +C-INTERCAL distribution's pit directory of sample code.) \} .bp .H 1 "ERROR MESSAGES" +.if '\*c'y' \{\ +.DS I F +Alice felt dreadfully puzzled. The Hatter's remark seemed to her to +have no sort of meaning in it, and yet it was certainly English. "I +don't quite understand you," she said, as politely as she could. +.DE \} .SETR error_messages .P Due to INTERCAL's implementation of comment lines (see section 4.5), most @@ -2411,7 +2573,7 @@ You tried to use a C-INTERCAL extension with the `traditional' flag on. .LI 127 Can't find syslib.i file when it's needed for magical inclusion. .LI 222 -Out of stash space. +Out of stash space, or attempt to stash an undeclared array. .LI 333 Too many variables. .LI 444 @@ -2423,23 +2585,46 @@ Too many source lines. .LI 777 No such source file. .LI 888 -Can't open C output file +Can't open C output file. .LI 999 Can't open C skeleton file. .LI 998 -Source file name with invalid extension (use .i or .[3-7]i). +Source file name with invalid extension (use .i or .[2-7]i). .LI 997 Illegal possession of a controlled unary operator. .LE \} .if '\*c'y' \{\ .H 1 "The C-INTERCAL Compiler" +.if '\*c'y' \{\ +.DS I F +"And yet it was a very clever pudding to invent." +.P +"What did you mean it to be made of?" Alice asked, hoping to cheer him +up, for the poor Knight seemed quite low-spirited about it. +.P +"It began with blotting-paper," the Knight answered with a groan. +.P +"That wouldn't be very nice, I'm afraid --" +.P +"Not very nice \fIalone\fR," he interrupted, quite eagerly, "but +you've no idea what a difference it makes, mixing it with other +things -- such as gunpowder and sealing-wax." +.DE \} +.P +This section describes the use of ick, the C-INTERCAL +compiler. Information specific to the other known INTERCAL compilers +appears in the following sections. These sections are less useful, +since the other compilers are no longer available, but they are +retained to provide a sense of history, and because any information +regarding INTERCAL is really too scarce to discard. .H 2 "Character Set" .P The C-INTERCAL compiler uses ASCII rather than EBCDIC. We follow the -Atari implementation by (a) replacing the change sign (\*(ct) with +Atari implementation (see section +.GETHN atari +) by (a) replacing the change sign (\*(ct) with big money ($) as the mingle operator, and (b) replacing the -bookworm (\*(vb) symbol with what (?) as the exclusive-or -operator. +bookworm (\*(vb) symbol with what (?) as the XOR operator. .H 2 "Usage and Compilation Options" .P To compile an INTERCAL program `foo.i' to executable code, just do @@ -2451,11 +2636,11 @@ inspection (suppressing compilation to machine code), a -d option that enables verbose parse reporting from the yacc/bison parser, a -t option that requires strict INTERCAL-72 compliance (rejecting COME FROM and the extensions for bases other than two), a -b option that -disables the INTERCAL-72 random-bug feature (E774), and an -O option -that enables the (hah!) optimizer. Invoking ick -? prints a usage +disables the INTERCAL-72 random-bug feature (error 774), and an -O option +that enables the (hah!) optimizer. Invoking ick -? prints a usage message. .P -Another compilation switch affects C-INTERCAL's runtime behavior. The `-C' +Another compilation switch affects C-INTERCAL's runtime behavior. The `-C' option forces output in "clockface" mode, for superstitious users who believe writing "IV" upside-down offends IVPITER and would rather see IIII. @@ -2469,29 +2654,37 @@ The help option (with either + or -) triggers a 'usage' message. The Steve explains: "The wimpmode option is the most interesting. I found myself always running my test programs with filters on both ends to work around the \&'nifty' INTERCAL number representations. This was so -painful that I decided it would be LESS painful (and a lot less code) -if I added a 'wimp' option. With the +wimpmode option, the user is -subjected to a humiliating message about what a wimp he or she is to -use this mode, but after that is allowed to use conventional numerical -notation. While such a mode doubtless violates to some extent the -INTERCAL philosophy, the fact that a 'unbutcher' command has been -posted clearly indicates the need for it. Anyway... if you don't like -it, don't use it... the default is -wimpmode (i.e. NOT wimp mode)." +painful that I decided it would be \fIless\fR painful (and a lot less +code) if I added a 'wimp' option. With the +wimpmode option, the user +is subjected to a humiliating message about what a wimp he or she is +to use this mode, but after that is allowed to use conventional +numerical notation. While such a mode doubtless violates to some +extent the INTERCAL philosophy, the fact that an 'unbutcher' command +has been posted clearly indicates the need for it. Anyway ... if you +don't like it, don't use it ... the default is -wimpmode +(i.e. \fInot\fR wimp mode)." .H 2 "PLEASE Politesse Checking" .P A feature of INTERCAL-72 not documented in the original manual was that it -required a certain level of politesse from the programmer. If fewer than +required a certain level of politesse from the programmer. If fewer than 1/5th of the program statements included the PLEASE qualifier, the program -would be rejected as insufficiently polite. If more than 1/3rd of them +would be rejected as insufficiently polite. If more than 1/3rd of them included PLEASE, the program would be rejected as excessively polite. .P -This check has been implemented in C-INTERCAL. To assist programmers in +This check has been implemented in C-INTERCAL. To assist programmers in coping with it, the intercal.el mode included with the distribution randomly -expands "do " in entered source to "DO PLEASE" or "PLEASE DO" 1/4th of the -time. \} +expands "do " in entered source to "PLEASE DO" 1/4th of the time. \} .if '\*c'y' \{\ .\" This is the same text as the ATARI NOTES at the end of the manual. .H 1 "The Atari Implementation" +.if '\*c'y' \{\ +.DS I F +"Perhaps it doesn't understand English," thought Alice. "I daresay +it's a French mouse, come over with William the Conqueror." (For, with +all her knowledge of history, Alice had no very clear notion how long +ago anything had happened.) +.DE \} +.SETR atari .P The Atari implementation of INTERCAL differs from the original Princeton version primarily in the use of ASCII rather than EBCDIC. Since there is no @@ -2499,30 +2692,37 @@ version primarily in the use of ASCII rather than EBCDIC. Since there is no mingle operator. We feel that this correctly represents the increasing cost of software in relation to hardware. (Consider that in 1970 one could get RUNOFF for free, to run on a $20K machine, whereas today a not quite as -powerful formatter costs $99 and runs on a $75 machine.) We also feel that +powerful formatter costs $99 and runs on a $75 machine.) We also feel that there should be no defensible contention that INTERCAL has any sense. Also, since overpunches are difficult to read on the average VDT, the -exclusive-or operator may be written ?. This correctly expresses the +exclusive-or operator may be written ?. This correctly expresses the average person's reaction on first encountering exclusive-or, especially on -a PDP-11. Note that in both of these cases, the over-punched symbol may +a PDP-11. Note that in both of these cases, the over-punched symbol may also be used if one is masochistic, or concerned with portability to the -Princeton compiler. The correct over-punch for "change" is "c/" -and the correct over-punch for \*(vb is "V-". These codes will be +Princeton compiler. The correct over-punch for "change" is "c/" +and the correct over-punch for \*(vb is "V-". These codes will be properly printed if you have a proper printer, and the corresponding EBCDIC code will be produced by the /IBM option on the LIST command. \} -.ie '\*c'n' \{\ +.if '\*c'n' \{\ .H 1 "JCL" +.SETR princeton .P The information contained in the following section applies only to the Princeton compiler, run under OS/360. .H 2 "The Princeton Compiler" \} -.el .H 1 "The Princeton Compiler" +.if '\*c'y' \{\ +.H 1 "The Princeton Compiler" +.DS I F +"My name is Alice, so please your Majesty," said Alice very politely; +but she added, to herself, "Why, they're only a pack of cards, after +all. I needn't be afraid of them!" +.DE \} +.SETR princeton .P The Princeton compiler, written in SPITBOL (a variant of SNOBOL), performs the compilation in two stages. First the INTERCAL source is converted into SPITBOL source, then the latter is compiled and executed. -.SETR princeton .P It should be noted that the Princeton compiler fails to properly interpret certain multiply-subscripted expressions, @@ -2542,7 +2742,9 @@ are unreadable enough as is. .P Since there is currently no catalogued procedure for invoking the compiler, the user must include the in-line -procedure shown on the following page in his job before the +.\" CORRECTION: +.\" "in Figure 3" was "on the following page" +procedure shown in Figure 3 in his job before the compilation step. Copies of this in-line procedure may be obtained at any keypunch if the proper keys are struck. .P @@ -2563,7 +2765,12 @@ procedure. At most one parameter from each set may apply to a given compilation; if more than one are specified, the results are undefined, and may vary depending upon the particular set of options. The default parameters are -underlined. +.if n \{\ +underlined.\} +.if t \{\ +italicized.\} +.\" CORRECTION: +.\" In the original, the footnote was on the wrong line (one above). .DS L //INTERCAL PROC //COMPILE EXEC PGM=INTERCAL @@ -2572,8 +2779,8 @@ underlined. //SYSPRINT DD SYSOUT=A,DCB=(BLKSIZE=992,LRECL=137,RECFM=VBA) //SYSPUNCH DD DUMMY //SCRATCH DD DSN=&COMPSET,UNIT=SYSDA,SPACE=(CYL,(3,1)),DISP=(,PASS) - //EXECUTE EXEC PGM=EXECUTE,COND=(4,LT) \*F - //SOURCES DD DSN=U.INTERCAL.SOURCES,DISP=SHR + //EXECUTE EXEC PGM=EXECUTE,COND=(4,LT) + //SOURCES DD DSN=U.INTERCAL.SOURCES,DISP=SHR \*F //STEPLIB DD DSN=U.INTERCAL.LIBRARY,DISP=SHR // DD DSN=SYS5.SPITLIB,DISP=SHR // DD DSN=SYS1.FORTLIB,DISP=SHR @@ -2598,7 +2805,7 @@ DD card must be replaced by the five cards: Figure 3. Inline procedure for using INTERCAL. .P .LB 5 0 " " 0 * 0 0 -.LI "\fBOPT\fR" +.LI "\fIOPT\fR" .LI "NOOPT" .LI " " In the default mode, the compiler will print a @@ -2608,19 +2815,20 @@ effective option for those sets where one was specified. If NOOPT is requested, it causes the default mode to be assumed. -.LI "\fBOPTSUB\fR +.LI "\fIOPTSUB\fR" .LI "NOOPTSUB" .LI "NOSUB" .LI " " Unless 'NOOPTSUB' is requested, the System Library is optimized, resulting in much more rapid -NOSUB processing of function calls. Specifying NOOPTSUB -causes the non-optimized INTERCAL code shown in -section 6.3 to be used, whereas NOSUB requests +processing of function calls. Specifying NOOPTSUB +causes the non-optimized INTERCAL code shown in section +.GETHN syslib + to be used, whereas NOSUB requests that the System Library be omitted altogether. .LI IAMBIC -.LI "\fBPROSE\fR +.LI "\fIPROSE\fR" .LI " " The IAMBIC parameter permits the programmer to use poetic license and thus write in verse. If the @@ -2629,7 +2837,7 @@ in INTERCAL, he should send the authors a stamped, self-addressed envelope, along with any INTERCAL program, and they will provide one which is verse. -.LI "\fBFORMAT\fR" +.LI "\fIFORMAT\fR" .LI NOFORMAT .LI " " In FORMAT mode, each statement printed is put on a @@ -2641,20 +2849,20 @@ and they may be only approximate. Also, unrecognizable statements are not flagged. .LI SEQ -.LI "\fBNOSEQ\fR" +.LI "\fINOSEQ\fR" .LI " " If the source deck has sequence numbers in columns 73 through 80, specifying 'SEQ' will cause them to be ignored. .LI "SOURCE" -.LI "\fBNOSOURCE\fR" +.LI "\fINOSOURCE\fR" .LI " " If NOSOURCE is selected, all source listing is suppressed. .LI LIST -.LI "\fBNOLIST\fR" +.LI "\fINOLIST\fR" .LI " " If LIST is specified, the compiler will provide a list of statement numbers catalogued according to @@ -2669,7 +2877,7 @@ default is .B 132. .LI "CODE" -.LI "\fBNOCODE\fR" +.LI "\fINOCODE\fR" .LI " " Include 'CODE' in the parameter list to obtain a listing of the SPITBOL code produced for each @@ -2683,21 +2891,21 @@ default is .B 60. .LI DECK -.LI "\fBNODECK\fR" +.LI "\fINODECK\fR" .LI " " Selecting 'DECK' will cause the compiler to punch out a SPITBOL object deck which may then be run without reinvoking the INTERCAL (or SPITBOL) compiler. -.LI "\fBKIDDING\fR" +.LI "\fIKIDDING\fR" .LI NOKIDDING .LI " " Select NOKIDDING to eliminate the snide remarks which ordinarily accompany INTERCAL error messages. -.LI "\fBGO\fR" +.LI "\fIGO\fR" .LI NOGO .LI " " Specifying 'NOGO' will cause the program to be @@ -2705,14 +2913,16 @@ compiled but not executed. EXECUTE/NOEXECUTE may be substituted for GO/NOGO, but this will result in an error, and GO will be assumed. -.LI "\fBBUG\fR" +.LI "\fIBUG\fR" .LI NOBUG .LI " " Under the default, there is a fixed probability of a fatal compiler bug being worked at random into the program being compiled. Encountering this bug during execution results in error message 774 (see -section 7.2). This probability is reduced to zero +section +.GETHN error_messages +). This probability is reduced to zero under 'NOBUG'. This does not affect the probability (presumably negligible) of error message 778. @@ -2726,13 +2936,29 @@ some notes on an Atari implementation included at the end of the manual. So, you expect compiler manuals to be consistent? .FE .ds App TONSIL -.APP A "" +.APP "A\*F" "" +.if '\*c'y' \{\ +.DS I F +"Of course they answer to their names?" the Gnat remarked carelessly. +.P +"I never knew them to do it." +.P +"What's the use of their having names," the Gnat said, "if they wo'n't +answer to them?" +.P +"No use to \fIthem\fR," said Alice; "but it's useful to the people +that name them, I suppose. If not, why do things have names at all?" +.P +"I ca'n't say," the Gnat replied. "Further on, in the wood down there, +they've got no names -- however, go on with your list...." +.DE \} .P The Official INTERCAL Character Set .FS Since all other reference manuals have Appendices, it was decided that the INTERCAL manual should contain some other type of removable organ. .FE +.ps \n[@ps] .\".nr * \n*+1 .nr PG \n%+1 .P @@ -2740,63 +2966,113 @@ Tabulated on page \n(PG are all the characters used in INTERCAL, excepting letters and digits, along with their names and interpretations. Also included are several characters not used in INTERCAL, which are presented for completeness and to allow for future expansion. +.\" All we're doing here is evaluating \*F and throwing it away +.fi \*F .FS -\*F This footnote intentionally unreferenced. +This footnote intentionally unreferenced. .FE .ds CH - % - .bp .\".nr * \n*-1 +.ps \n[@ps] +.ie '\*c'n' \{\ +.TS +box; +c c c +l l l. +Character Name Use (if any) +\&. spot identify 16-bit variable +: two-spot identify 32-bit variable +, tail identify 16-bit array +; hybrid identify 32-bit array +# mesh identify constant +\&= half-mesh +\' spark grouper +` backspark +! wow equivalent to spark-spot +? what \fIunary exlusive OR (ASCII)\fR +" rabbit-ears grouper +\o'".' rabbit equivalent to ears-spot +| spike +% double-oh-seven percentage qualifier +\- worm used with angles +< angle used with worms +> right angle +( wax precedes line label +) wane follows line label +[ U turn +] U turn back +{ embrace +} bracelet +* splat flags invalid statements +& ampersand \*F unary logical AND +V V (or book) unary logical OR +\*(vb bookworm (or universal qualifier) unary exclusive OR +$ big money \fIbinary mingle (ASCII)\fR +\*(ct change binary mingle +~ sqiggle binary select +\&_ flat worm +\*(ov overline indicates "times 1000" ++ intersection separates list items +/ slat +\e backslat +@ whirlpool +\*(no hookworm +^ shark (or simply sharkfin) +\o"#*\(sq" blotch +.TE \} +.el \{\ .TS box; c c c l l l. -Character Name Use (if any) -= -\&. spot identify 16-bit variable -: two-spot identify 32-bit variable -, tail identify 16-bit array -; hybrid identify 32-bit array -# mesh identify constant -\&= half-mesh -\' spark grouper -` backspark -! wow equivalent to spark-spot -? what \fIunary exlusive OR (ASCII)\fR -" rabbit-ears grouper -\o'".' rabbit equivalent to ears-spot -| spike -% double-oh-seven percentage qualifier -\- worm used with angles -< angle used with worms -> right angle -( wax precedes line label -) wane follows line label -[ U turn -] U turn back -{ embrace -} bracelet -* splat flags invalid statements -& ampersand\*F unary logical AND -V V (or book) unary logical OR -\*(vb bookworm (or universal qualifier) unary exclusive OR -$ big money \fIbinary mingle (ASCII)\fR -\*(ct change binary mingle -~ sqiggle binary select -\&_ flat worm -\*(ov overline indicates "times 1000" -+ intersection separates list items -/ slat -\e backslat -@ whirlpool -\*(no hookworm -^ shark (or simply sharkfin) -\o"#*\(sq" blotch -.TE +Character Name Use (if any) +\&. spot identify 16-bit variable +: two-spot identify 32-bit variable +, tail identify 16-bit array +; hybrid identify 32-bit array +# mesh identify constant +\&= half-mesh +\' spark grouper +` backspark +! wow equivalent to spark-spot +? what unary logical XOR +" rabbit-ears grouper +\o'".' rabbit equivalent to ears-spot +| spike +% double-oh-seven percentage qualifier +\- worm used with angles +< angle used with worms +> right angle +( wax precedes line label +) wane follows line label +[ U turn +] U turn back +{ embrace +} bracelet +* splat flags invalid statements +& ampersand \*F unary logical AND +V V (or book) unary logical OR +\*(vb bookworm (universal qualifier) unary logical XOR (INTERCAL-72) +$ big money binary mingle +\*(ct change binary mingle (INTERCAL-72) +~ sqiggle binary select +\&_ flat worm +\*(ov overline indicates "times 1000" ++ intersection separates list items +/ slat +\e backslat +@ whirlpool unary logical BUT (TriINTERCAL) +\*(no hookworm +^ shark (or simply sharkfin) unary logical XOR (TriINTERCAL) +\o"#*\(sq" blotch +.TE \} .ce 1 Table 2 (top view). INTERCAL character set. .FS Got any better ideas? .FE +.ps \n[@ps] .if '\*c'n' \{\ .APP "B" "NOTES ON THE ATARI IMPLEMENTATION" .P @@ -2807,14 +3083,14 @@ version primarily in the use of ASCII rather than EBCDIC. Since there is no mingle operator. We feel that this correctly represents the increasing cost of software in relation to hardware. (Consider that in 1970 one could get RUNOFF for free, to run on a $20K machine, whereas today a not quite as -powerful formatter costs $99 and runs on a $75 machine.) We also feel that +powerful formatter costs $99 and runs on a $75 machine.) We also feel that there should be no defensible contention that INTERCAL has any sense. Also, since overpunches are difficult to read on the average VDT, the -exclusive-or operator may be written ?. This correctly expresses the +exclusive-or operator may be written ?. This correctly expresses the average person's reaction on first encountering exclusive-or, especially on -a PDP-11. Note that in both of these cases, the over-punched symbol may +a PDP-11. Note that in both of these cases, the over-punched symbol may also be used if one is masochistic, or concerned with portability to the -Princeton compiler. The correct over-punch for "change" is "c/" -and the correct over-punch for \*(vb is "V-". These codes will be +Princeton compiler. The correct over-punch for "change" is "c/" +and the correct over-punch for \*(vb is "V-". These codes will be properly printed if you have a proper printer, and the corresponding EBCDIC code will be produced by the /IBM option on the LIST command. \} diff --git a/intercal.el b/intercal.el index 178d3d9..ae7a06b 100644 --- a/intercal.el +++ b/intercal.el @@ -3,6 +3,7 @@ ;; This mode was written by Eric S. Raymond ;; for the C-INTERCAL distribution, and is copyrighted by him 1992. Free ;; redistribution encouraged. Someday, maybe, this will be made part of GNU. +;; But probably not unless they take many mind-eroding drugs first. ;; This mode provides abbrevs for C-INTERCAL's statements, including COME FROM. ;; These abbrevs are context-sensitive and will generate either verb or gerund @@ -13,13 +14,13 @@ ;; INTERCAL-72 and C-INTERCAL releases after 0.7, no fewer than 1/5 and no ;; more than 1/3 of the program statements must contain a PLEASE to gratify ;; the iron whim of the INTERCAL compiler; this mode assists by randomly -;; expanding some fraction of the "do" abbrevs typed to PLEASE DO or DO PLEASE. +;; expanding some fraction of the "do" abbrevs typed to PLEASE DO. ;; The intercal-politesse-level constant is the denominator of this fraction. -;; $Id: intercal.el,v 1.4 1994/09/22 09:08:00 esr Exp $ +;; $Id: intercal.el,v 1.5 1996/11/14 04:02:00 esr Exp $ (defconst intercal-politesse-level 4 - "Fraction of DOs that are automagically expanded to PLEASE DO, DO PLEASE.") + "Fraction of DOs that are automagically expanded to PLEASE DO.") (defvar intercal-mode-map nil "Keymap for INTERCAL mode.") @@ -96,10 +97,10 @@ (make-intercal-abbrev intercal-co-abbrev "COMING FROM" "COME FROM") (defun intercal-do-abbrev () - "Emit a DO (usually). Occasionally, emit DO PLEASE or PLEASE DO." + "Emit a DO (usually). Occasionally, emit PLEASE DO." (insert (if (zerop (% (random) intercal-politesse-level)) - (if (% (random) 2) "PLEASE DO" "DO PLEASE") + "PLEASE DO" "DO") )) diff --git a/intercal.lsm b/intercal.lsm index 8fc1a75..42f7045 100644 --- a/intercal.lsm +++ b/intercal.lsm @@ -1,7 +1,7 @@ Begin3 Title: intercal -Version: 0.15 -Entered-date: Thu Jun 20 17:42:36 EDT 1996 +Version: 0.16 +Entered-date: 26MAY97 Description: An implementation of the language INTERCAL, legendary for its perversity and horribleness (this version adds COME FROM for extra flavor). Comes with language manual and examples @@ -10,8 +10,8 @@ Keywords: language, compiler, retrocomputing, geek humor Author: esr@snark.thyrsus.com (Eric S. Raymond) Maintained-by: esr@snark.thyrsus.com (Eric S. Raymond) Primary-site: locke.ccil.org /pub/esr - intercal-0.15 -Platform: All + 166K intercal-0.16.tar.gz +Platforms: All Copying-policy: GPL End diff --git a/pit/CATALOG b/pit/CATALOG index 5c20e83..20d55b8 100644 --- a/pit/CATALOG +++ b/pit/CATALOG @@ -12,9 +12,10 @@ Contents: from original manual: sample.i Returns absolute value of a 16-bit 2s-complement number + lib/syslib.i Standard library, with bugs fixed lib/syslib-orig.i Standard library (original buggy version) -by Jon Blow +by Jon Blow sink.i Simple test program random.i Random number program lib/plus.i Increment .1 @@ -25,7 +26,7 @@ by Hans Olsson it's there in our lib/syslib.i. We keep this around as an example. (What? Throw away INTERCAL code? Perish the thought!) -by Louis Howell +by Louis Howell life.i Conway's game of Life, standard INTERCAL version life2.i This version uses COME FROM and character output blinkers @@ -34,35 +35,65 @@ by Louis Howell gun Input files for both Life programs bubble.i Bubble sort icat.i Sends input to output - lib/lib2.i Currently contains only a decrement routine, see life.doc + lib/lib2.i New library routines: decrement, decrement and branch on 0, + add bit, 16-bit division with remainder, exponentiation pi.i Calculate pi primes.i Find prime numbers - pow.i prints a list of nth powers (test of exponentiation routine) - lib/syslib.i Corrected version of system library. - -by Matt Dimeo, via http://www.ionet.net/~timtroyr/funhouse/beer.html + pow.i Prints a list of nth powers using old exponentiation routine + lib/syslib.i Corrected version of system library + iching1.i Generates I Ching hexagrams + iching2.i This version uses a lookup table to find the sequence number + iching.doc Description of the two I Ching programs + change.i Count up different ways to make change + change.doc Description of change.i + +by Matt Dimeo beer.i Print out the lyrics to "99 Bottles of Beer On The Wall" by Stinglai Ka'abi : random2.i Another random-number generator by Jacob Mandelson - rot13.i a ROT13 filter in INTERCAL + rot13.i Prints ROT-13 of its input by Jan-Pieter Cornet - hail_mary.3i print 1,000,000 Hail Marys - count.3i count from 1 to 10 in TriINTERCAL + hail_mary.3i Print 1,000,000 Hail Marys + count.3i Count from 1 to 10 in TriINTERCAL + iogerunds.i Demonstrate gerund abstention + +by Clemens Meier + rot13b.i Another ROT-13 program By Brian Raiter - lib/numio.i I/O routines - lib/numio.doc description of the I/O routines + lib/numio.i I/O routines + lib/numio.doc Description of the I/O routines + lib/syslib.3i + lib/syslib.4i + lib/syslib.5i + lib/syslib.6i Translations of the standard library to + lib/syslib.7i C-INTERCAL's other bases. + lib/syslib3-7.doc Documentation for same + hello.i The traditional hello world program + ins.i Intersections & Splats, a Mastermind-style game + ins.doc Documentation for I&S + yapp.i Prints an INTERCAL program that prints + yapp.doc Description of yapp.i + quine.i Prints itself + lib/floatlib.i Floating-point routines + lib/floatlib.doc Documentation for the floating-point routines + flonck.i An RPN calculator + flonck.doc Documentation for flonck.i + fft.i Fast Fourier Transform + fft.doc Description of fft.i + delta.fft + tophat.fft Sample input for FFT The subdirectory tests contains some programs written only to test the compiler. by David Moews - test1.i prints DO THIS TEST HAS BEEN SUCCESSFULLY COMPLETED - test2.i reads in two numbers and multiplies their product + test1.i Prints DO THIS TEST HAS BEEN SUCCESSFULLY COMPLETED + test2.i Reads in two numbers and multiplies their product David Moews wrote of the latter (test2.i): @@ -72,10 +103,7 @@ of a portion of the INTERCAL subroutine library. (Only a portion of the INTERCAL subroutine library is present in the posted manual, and that portion is full of typos.) -by Jan-Pieter Cornet - iogerunds.i demonstrate gerund abstention - -The programs test16bit.i, testarray.i, testcf.i, testlib2.i, +The programs test16bit.i, testarray.i, testcf.i, testlib2.i, mult.i, limits.{i,3i}, testops.{3i,5i}, testsplat.i, were all written by Louis Howell. Of these, testcf.i might be considered an interesting puzzle---try to figure out what it's doing. The others are pretty diff --git a/pit/Makefile b/pit/Makefile index 4f30b67..68592c8 100644 --- a/pit/Makefile +++ b/pit/Makefile @@ -10,28 +10,42 @@ SOURCES = \ ./hail_mary.3i \ ./icat.i \ ./tests/limits.i \ + ./tests/limits.3i \ ./tests/test1.i \ ./tests/test16bit.i \ ./tests/testarray.i \ ./tests/testcf.i \ ./tests/testlib2.i \ ./tests/test2.i \ - ./tests/testlimits.i \ + ./tests/testops.3i \ + ./tests/testops.5i \ ./tests/testsplat.i \ ./pow.i \ ./random.i \ ./random2.i \ ./rot13.i \ + ./rot13b.i \ ./iogerunds.i \ ./pi.i \ ./lib/lib2.i \ ./lib/numio.i \ ./lib/syslib.i \ + ./lib/syslib.3i \ + ./lib/syslib.4i \ + ./lib/syslib.5i \ + ./lib/syslib.6i \ + ./lib/syslib.7i \ ./lib/plus.i \ ./primes.i \ ./life.i \ ./life2.i \ - ./sink.i + ./sink.i \ + ./change.i \ + ./iching1.i \ + ./iching2.i \ + ./hello.i \ + ./ins.i \ + ./yappp.i TARGETS = \ ./sample \ @@ -47,12 +61,13 @@ TARGETS = \ ./tests/testcf \ ./tests/testlib2 \ ./tests/test2 \ - ./tests/testlimits \ + ./tests/testops \ ./tests/testsplat \ ./pow \ ./random \ ./random2 \ ./rot13 \ + ./rot13b \ ./iogerunds \ ./pi \ ./lib/lib2 \ @@ -62,14 +77,24 @@ TARGETS = \ ./primes \ ./life \ ./life2 \ - ./sink + ./sink \ + ./change \ + ./iching1 \ + ./iching2 \ + ./hello \ + ./ins \ + ./yappp test: for x in $(SOURCES); do echo "Test-compiling $$x"; ../src/ick -b $$x; done +otest: + for x in $(SOURCES); do echo "Test-compiling $$x"; ../src/ick -O -b $$x; done + lines: wc -l $(SOURCES) clean: - rm -f $(TARGETS) + rm -f $(TARGETS) *.c *.o + diff --git a/pit/beer.doc b/pit/beer.doc new file mode 100644 index 0000000..4bc1361 --- /dev/null +++ b/pit/beer.doc @@ -0,0 +1,368 @@ +// This is beer.doc. Strip out all comments to have a valid INTERCAL +// program beer.i that prints out the complete lyrics to 99 Bottles of Beer +// on the Wall. The string arrays were computed by a 115 line perl +// program. +// It cops out and relies on the standard library routines for +// addition and subtraction to do the x++ operation. +// -Matt DiMeo +// -mdimeo@brooktree.com + +// ,10 is a bare newline from scratch. +PLEASE DO ,10 <- #1 +PLEASE DO ,10SUB#1 <- #176 +// ,11 is bottles of beer on the wall, +PLEASE DO ,11 <- #30 +PLEASE DO ,11SUB#1 <- #76 + DO ,11SUB#2 <- #190 + DO ,11SUB#3 <- #80 + DO ,11SUB#4 <- #200 +PLEASE DO ,11SUB#5 <- #256 + DO ,11SUB#6 <- #248 + DO ,11SUB#7 <- #144 + DO ,11SUB#8 <- #216 +PLEASE DO ,11SUB#9 <- #202 + DO ,11SUB#10 <- #14 + DO ,11SUB#11 <- #144 + DO ,11SUB#12 <- #98 +PLEASE DO ,11SUB#13 <- #190 + DO ,11SUB#14 <- #160 + DO ,11SUB#15 <- #256 + DO ,11SUB#16 <- #88 +PLEASE DO ,11SUB#17 <- #74 + DO ,11SUB#18 <- #14 + DO ,11SUB#19 <- #128 + DO ,11SUB#20 <- #114 +PLEASE DO ,11SUB#21 <- #214 + DO ,11SUB#22 <- #24 + DO ,11SUB#23 <- #112 + DO ,11SUB#24 <- #162 +PLEASE DO ,11SUB#25 <- #22 + DO ,11SUB#26 <- #104 + DO ,11SUB#27 <- #80 + DO ,11SUB#28 <- #256 +PLEASE DO ,11SUB#29 <- #2 + DO ,11SUB#30 <- #228 +// ,12 is bottles of beer.\nTake one down, pass it around, +PLEASE DO ,12 <- #49 +PLEASE DO ,12SUB#1 <- #76 + DO ,12SUB#2 <- #190 + DO ,12SUB#3 <- #80 + DO ,12SUB#4 <- #200 +PLEASE DO ,12SUB#5 <- #256 + DO ,12SUB#6 <- #248 + DO ,12SUB#7 <- #144 + DO ,12SUB#8 <- #216 +PLEASE DO ,12SUB#9 <- #202 + DO ,12SUB#10 <- #14 + DO ,12SUB#11 <- #144 + DO ,12SUB#12 <- #98 +PLEASE DO ,12SUB#13 <- #190 + DO ,12SUB#14 <- #160 + DO ,12SUB#15 <- #256 + DO ,12SUB#16 <- #88 +PLEASE DO ,12SUB#17 <- #218 + DO ,12SUB#18 <- #36 + DO ,12SUB#19 <- #38 + DO ,12SUB#20 <- #164 +PLEASE DO ,12SUB#21 <- #176 + DO ,12SUB#22 <- #48 + DO ,12SUB#23 <- #162 + DO ,12SUB#24 <- #14 +PLEASE DO ,12SUB#25 <- #128 + DO ,12SUB#26 <- #208 + DO ,12SUB#27 <- #162 + DO ,12SUB#28 <- #222 +PLEASE DO ,12SUB#29 <- #48 + DO ,12SUB#30 <- #8 + DO ,12SUB#31 <- #120 + DO ,12SUB#32 <- #66 +PLEASE DO ,12SUB#33 <- #48 + DO ,12SUB#34 <- #246 + DO ,12SUB#35 <- #136 + DO ,12SUB#36 <- #184 +PLEASE DO ,12SUB#37 <- #256 + DO ,12SUB#38 <- #202 + DO ,12SUB#39 <- #110 + DO ,12SUB#40 <- #104 +PLEASE DO ,12SUB#41 <- #42 + DO ,12SUB#42 <- #126 + DO ,12SUB#43 <- #56 + DO ,12SUB#44 <- #88 +PLEASE DO ,12SUB#45 <- #72 + DO ,12SUB#46 <- #56 + DO ,12SUB#47 <- #80 + DO ,12SUB#48 <- #242 +PLEASE DO ,12SUB#49 <- #228 +// ,13 is bottles of beer on the wall. +PLEASE DO ,13 <- #31 +PLEASE DO ,13SUB#1 <- #76 + DO ,13SUB#2 <- #190 + DO ,13SUB#3 <- #80 + DO ,13SUB#4 <- #200 +PLEASE DO ,13SUB#5 <- #256 + DO ,13SUB#6 <- #248 + DO ,13SUB#7 <- #144 + DO ,13SUB#8 <- #216 +PLEASE DO ,13SUB#9 <- #202 + DO ,13SUB#10 <- #14 + DO ,13SUB#11 <- #144 + DO ,13SUB#12 <- #98 +PLEASE DO ,13SUB#13 <- #190 + DO ,13SUB#14 <- #160 + DO ,13SUB#15 <- #256 + DO ,13SUB#16 <- #88 +PLEASE DO ,13SUB#17 <- #74 + DO ,13SUB#18 <- #14 + DO ,13SUB#19 <- #128 + DO ,13SUB#20 <- #114 +PLEASE DO ,13SUB#21 <- #214 + DO ,13SUB#22 <- #24 + DO ,13SUB#23 <- #112 + DO ,13SUB#24 <- #162 +PLEASE DO ,13SUB#25 <- #22 + DO ,13SUB#26 <- #104 + DO ,13SUB#27 <- #80 + DO ,13SUB#28 <- #256 +PLEASE DO ,13SUB#29 <- #194 + DO ,13SUB#30 <- #36 + DO ,13SUB#31 <- #256 + +// ,20 MAPS NEWLINES TO DIGITS +PLEASE DO ,20 <- #10 +PLEASE DO ,20 SUB #1 <- #76 + DO ,20 SUB #2 <- #196 + DO ,20 SUB #3 <- #4 + DO ,20 SUB #4 <- #132 +PLEASE DO ,20 SUB #5 <- #36 + DO ,20 SUB #6 <- #164 + DO ,20 SUB #7 <- #228 + DO ,20 SUB #8 <- #100 +PLEASE DO ,20 SUB #9 <- #52 + DO ,20 SUB #10 <- #180 + +// ,21 MAPS DIGITS TO DIGITS +PLEASE DO ,21 <- #10 BY #10 +PLEASE DO ,21SUB#1#1 <- #248 +PLEASE DO ,21SUB#1#2 <- #120 +PLEASE DO ,21SUB#1#3 <- #184 +PLEASE DO ,21SUB#1#4 <- #56 +PLEASE DO ,21SUB#1#5 <- #216 +PLEASE DO ,21SUB#1#6 <- #88 +PLEASE DO ,21SUB#1#7 <- #152 +PLEASE DO ,21SUB#1#8 <- #24 +PLEASE DO ,21SUB#1#9 <- #232 +PLEASE DO ,21SUB#1#10 <- #104 + DO ,21SUB#2#1 <- #128 + DO ,21SUB#2#2 <- #256 + DO ,21SUB#2#3 <- #64 + DO ,21SUB#2#4 <- #192 + DO ,21SUB#2#5 <- #96 + DO ,21SUB#2#6 <- #224 + DO ,21SUB#2#7 <- #32 + DO ,21SUB#2#8 <- #160 + DO ,21SUB#2#9 <- #112 + DO ,21SUB#2#10 <- #240 + DO ,21SUB#3#1 <- #64 + DO ,21SUB#3#2 <- #192 + DO ,21SUB#3#3 <- #256 + DO ,21SUB#3#4 <- #128 + DO ,21SUB#3#5 <- #32 + DO ,21SUB#3#6 <- #160 + DO ,21SUB#3#7 <- #224 + DO ,21SUB#3#8 <- #96 + DO ,21SUB#3#9 <- #48 + DO ,21SUB#3#10 <- #176 + DO ,21SUB#4#1 <- #192 + DO ,21SUB#4#2 <- #64 + DO ,21SUB#4#3 <- #128 + DO ,21SUB#4#4 <- #256 + DO ,21SUB#4#5 <- #160 + DO ,21SUB#4#6 <- #32 + DO ,21SUB#4#7 <- #96 + DO ,21SUB#4#8 <- #224 + DO ,21SUB#4#9 <- #176 + DO ,21SUB#4#10 <- #48 +PLEASE DO ,21SUB#5#1 <- #32 +PLEASE DO ,21SUB#5#2 <- #160 +PLEASE DO ,21SUB#5#3 <- #224 +PLEASE DO ,21SUB#5#4 <- #96 +PLEASE DO ,21SUB#5#5 <- #256 +PLEASE DO ,21SUB#5#6 <- #128 +PLEASE DO ,21SUB#5#7 <- #192 +PLEASE DO ,21SUB#5#8 <- #64 +PLEASE DO ,21SUB#5#9 <- #16 +PLEASE DO ,21SUB#5#10 <- #144 + DO ,21SUB#6#1 <- #160 + DO ,21SUB#6#2 <- #32 + DO ,21SUB#6#3 <- #96 + DO ,21SUB#6#4 <- #224 + DO ,21SUB#6#5 <- #128 + DO ,21SUB#6#6 <- #256 + DO ,21SUB#6#7 <- #64 + DO ,21SUB#6#8 <- #192 + DO ,21SUB#6#9 <- #144 + DO ,21SUB#6#10 <- #16 + DO ,21SUB#7#1 <- #96 + DO ,21SUB#7#2 <- #224 + DO ,21SUB#7#3 <- #32 + DO ,21SUB#7#4 <- #160 + DO ,21SUB#7#5 <- #64 + DO ,21SUB#7#6 <- #192 + DO ,21SUB#7#7 <- #256 + DO ,21SUB#7#8 <- #128 + DO ,21SUB#7#9 <- #80 + DO ,21SUB#7#10 <- #208 + DO ,21SUB#8#1 <- #224 + DO ,21SUB#8#2 <- #96 + DO ,21SUB#8#3 <- #160 + DO ,21SUB#8#4 <- #32 + DO ,21SUB#8#5 <- #192 + DO ,21SUB#8#6 <- #64 + DO ,21SUB#8#7 <- #128 + DO ,21SUB#8#8 <- #256 + DO ,21SUB#8#9 <- #208 + DO ,21SUB#8#10 <- #80 +PLEASE DO ,21SUB#9#1 <- #16 +PLEASE DO ,21SUB#9#2 <- #144 +PLEASE DO ,21SUB#9#3 <- #208 +PLEASE DO ,21SUB#9#4 <- #80 +PLEASE DO ,21SUB#9#5 <- #240 +PLEASE DO ,21SUB#9#6 <- #112 +PLEASE DO ,21SUB#9#7 <- #176 +PLEASE DO ,21SUB#9#8 <- #48 +PLEASE DO ,21SUB#9#9 <- #256 +PLEASE DO ,21SUB#9#10 <- #128 + DO ,21SUB#10#1 <- #144 + DO ,21SUB#10#2 <- #16 + DO ,21SUB#10#3 <- #80 + DO ,21SUB#10#4 <- #208 + DO ,21SUB#10#5 <- #112 + DO ,21SUB#10#6 <- #240 + DO ,21SUB#10#7 <- #48 + DO ,21SUB#10#8 <- #176 + DO ,21SUB#10#9 <- #128 + DO ,21SUB#10#10 <- #256 + +// ,22 MAPS DIGITS TO SPACES +PLEASE DO ,22 <- #10 +PLEASE DO ,22 SUB #1 <- #8 + DO ,22 SUB #2 <- #136 + DO ,22 SUB #3 <- #72 + DO ,22 SUB #4 <- #200 +PLEASE DO ,22 SUB #5 <- #40 + DO ,22 SUB #6 <- #168 + DO ,22 SUB #7 <- #104 + DO ,22 SUB #8 <- #232 +PLEASE DO ,22 SUB #9 <- #24 + DO ,22 SUB #10 <- #152 + +// ,10 ,11 ,12 ,20 ,21 and ,22 are defined by the makestrings script + +// .10 contains first digit, .11 contains second. + DO .10 <- #9 + DO .11 <- #9 + +// ,10 prints a newline from scratch +PLEASE DO ,10 <- #1 +PLEASE DO ,10SUB#1 <- #176 + DO READ OUT ,10 // print a bare newline. + + DO COME FROM (999) // main loop. + DO (500) NEXT // print the two digit number .10 .11 + // returning the offset to get to a space + // in .5. +PLEASE DO ,11SUB#1 <- .5 // bottles of beer on the wall + DO READ OUT ,11 + + DO (500) NEXT // print the two digit number .10 .11 + DO ,12SUB#1 <- .5 // bottles of beer. Take...around, +PLEASE DO READ OUT ,12 + + // .6 = (.10 == 0 ? 1 : 2) snagged from line 54 of library. +PLEASE DO .6 <- '?"!10~.10'~#1"$#1'~#3 + // this line, line 50, and line 51 form a conditional. + DO (50) NEXT + // end up here if .10 != 0 + + // conditional on .11==0? +PLEASE DO .7 <- '?"!11~.11'~#1"$#1'~#3 // same for .7 + DO (70) NEXT + // .11 != 0 + + // subtract 1 from .11 (second digit). + DO .2 <- #1 + DO .1 <- .11 +PLEASE DO (1010) NEXT // .3 = .1 - .2 = .11 - 1 + DO .11 <- .3 + DO (600) NEXT // print last verse line + DO (101) NEXT // jump out of loop. + +(70) DO (71) NEXT + // .11 == 0 + DO .11 <- #9 // roll over second digit + + // subtract 1 from first digit + DO .2 <- #1 +PLEASE DO .1 <- .10 + DO (1010) NEXT // .3 = .1 - .2 = .10 - 1 + DO .10 <- .3 + + DO (600) NEXT // print last verse line + DO (101) NEXT // jump out of loop. +(71) DO RESUME .7 // end if .11 == 0 + +(50) DO (51) NEXT +PLEASE DO FORGET #1 + // end up here if .10 == 0. + + // subtract 1 from .11 (second digit). + DO .2 <- #1 + DO .1 <- .11 +PLEASE DO (1010) NEXT // .3 = .1 - .2 = .11 - 1 + DO .11 <- .3 + + DO (600) NEXT // print last verse line +PLEASE DO .7 <- '?"!11~.11'~#1"$#1'~#3 // same for .7 + DO (80) NEXT + // .10 == 0, .11 != 0 + DO (101) NEXT + + +(80) DO (81) NEXT + // .10 == 0, .11 == 0 + + DO GIVE UP + +(81) DO RESUME .7 + + +(51) DO RESUME .6 // end if .10 == 0 + +(101) DO FORGET #1 + +(999) DO FORGET #1 // dummy statement + +// subroutine to print last line of a verse. +(600) DO (500) NEXT // print the two digit number .10 .11 + DO ,13SUB#1 <- .5 // bottles of beer on the wall. + DO READ OUT ,13 + DO RESUME #1 + +// subroutine to print a two digit number. The first digit is in .10, +// the second is in .11. Returns the index to be READ OUT to get to a +// space in .5. +(500) DO ,30 <- #1 // 1 elt array for printing. + DO .1 <- .10 // .1 gets first digit. + DO (1020) NEXT // .1++ +PLEASE DO ,30SUB#1 <- ,20SUB.1 // map from newline to digit + DO READ OUT ,30 // print the digit. + + // now we map from the first digit to the second digit. + DO .3 <- .1 // stash array index away. + DO .1 <- .11 // .1 gets second digit. + DO (1020) NEXT // .1++ +PLEASE DO ,30SUB#1 <- ,21SUB .3 .1 // map from first digit to second digit + DO READ OUT ,30 // print the digit. + DO .5 <- ,22SUB.1 // map to space and return that value. + +PLEASE DO RESUME #1 // return from (500) subrtn. diff --git a/pit/bubble.doc b/pit/bubble.doc index a513ff7..c847f63 100644 --- a/pit/bubble.doc +++ b/pit/bubble.doc @@ -13,10 +13,9 @@ was used, is included at the end of the file. ----------------------------------------------------------------------------- -Article: 120 of alt.lang.intercal -From: howell@grover.llnl.gov (Louis Howell) -Newsgroups: alt.lang.intercal Subject: Bubble sort routine +Newsgroups: alt.lang.intercal +From: Louis Howell Date: Thu, 7 Feb 91 18:56:34 PST I am including below an Intercal bubble sort routine along with a diff --git a/pit/change.doc b/pit/change.doc new file mode 100644 index 0000000..593823f --- /dev/null +++ b/pit/change.doc @@ -0,0 +1,31 @@ +The problem is to determine how many different ways there are to make +change for a given amount using five denominations of US coins +(including the 50-cent piece). One version -- taken directly from +section 1.2.2 of Abelson and Sussman (1st edition, 1985) -- recurses +both towards lower amounts and fewer kinds of coins. The space +required by this tree recursion grows rapidly with the size of the +problem. The other version is a minor modification which makes the +long ``amount'' direction tail-recursive. The ``kinds'' direction is +still recursive, but with only five kinds of coins there need be only +five stack frames for the routine allocated at a time. + +In case it isn't obvious, the routine starting at (100) is the +function ``first-denomination'' (one of the few things INTERCAL can do +easily), the one at (200) is the recursive version ``cc'', and (300) +starts the tail-recursive routine ``cc-tail''. The first few lines are +the main program, which you can change to run the recursive version by +calling (200) instead of (300). The (2000) routine at the end +decrements .1, and I make calls to the addition and subtraction +routines in the standard library. + +Two stacks are involved: the variable stack accessed by STASH and +RETRIEVE, and the call stack accessed by NEXT and RESUME. The former +is limited only by memory, but the latter is supposed to have a +built-in limit of 80 pending returns. The tail-recursive routine has +no problem with this. However, in order to permit the recursive +routine (200) to run with amounts greater than 70, I had to remake the +INTERCAL compiler with a larger limit. + + +(To see this program compared with similar programs in other languages, +visit http://www.webcom.com/nazgul/change.html.) \ No newline at end of file diff --git a/pit/change.i b/pit/change.i new file mode 100644 index 0000000..a43d102 --- /dev/null +++ b/pit/change.i @@ -0,0 +1,92 @@ + DO WRITE IN .4 + DO .5 <- #5 + DO .6 <- #0 + DO (300) NEXT + DO READ OUT .3 + PLEASE GIVE UP + +(100) DO (110) NEXT + DO .2 <- #50 + PLEASE RESUME #1 +(110) DO (120) NEXT + DO .2 <- #25 + PLEASE RESUME #2 +(120) DO (130) NEXT + DO .2 <- #10 + PLEASE RESUME #3 +(130) DO (140) NEXT + DO .2 <- #5 + PLEASE RESUME #4 +(140) DO (150) NEXT + DO .2 <- #1 + PLEASE RESUME #5 +(150) DO RESUME .5 + +(200) DO (201) NEXT + DO .3 <- #1 + DO RESUME #1 +(202) PLEASE RESUME '?"!4~.4'~#1"$#2'~#3 +(201) DO (202) NEXT + DO (203) NEXT + DO .3 <- #0 + DO RESUME #2 +(204) PLEASE RESUME '?"'&"?!4~#32768'$#1"$".5~.5"'~#1"$#2'~#3 +(203) DO (204) NEXT + PLEASE FORGET #2 + DO .1 <- .4 + DO (100) NEXT + DO (1010) NEXT + PLEASE STASH .4 + DO .4 <- .3 + DO (200) NEXT + PLEASE RETRIEVE .4 + PLEASE STASH .5 + .6 + DO .6 <- .3 + DO .1 <- .5 + DO (2000) NEXT + DO .5 <- .1 + DO (200) NEXT + DO .1 <- .3 + DO .2 <- .6 + PLEASE RETRIEVE .5 + .6 + DO (1000) NEXT + PLEASE RESUME #1 + + PLEASE COME FROM (310) +(300) DO (301) NEXT + DO .1 <- .6 + DO (1020) NEXT + DO .3 <- .1 + DO RESUME #1 +(302) PLEASE RESUME '?"!4~.4'~#1"$#2'~#3 +(301) DO (302) NEXT + DO (303) NEXT + DO .3 <- .6 + DO RESUME #2 +(304) PLEASE RESUME '?"'&"?!4~#32768'$#1"$".5~.5"'~#1"$#2'~#3 +(303) DO (304) NEXT + PLEASE FORGET #2 + DO .1 <- .5 + DO (2000) NEXT + PLEASE STASH .4 + .5 + DO .5 <- .1 + DO (300) NEXT + PLEASE RETRIEVE .4 + .5 + DO .6 <- .3 + DO .1 <- .4 + DO (100) NEXT + DO (1010) NEXT +(310) DO .4 <- .3 + +(2000) PLEASE STASH .2 + DO .2 <- #1 + DO (2001) NEXT +(2001) PLEASE FORGET #1 + DO .1 <- '?.1$.2'~'#0$#65535' + DO (2002) NEXT + DO .2 <- !2$#0'~'#32767$#1' + DO (2001) NEXT +(2003) PLEASE RESUME "?!1~.2'$#1"~#3 +(2002) DO (2003) NEXT + PLEASE RETRIEVE .2 +(2004) PLEASE RESUME #2 diff --git a/pit/count.doc b/pit/count.doc new file mode 100644 index 0000000..bfa98cc --- /dev/null +++ b/pit/count.doc @@ -0,0 +1,71 @@ + +From: johnpc@xs4all.nl (Jan-Pieter Cornet) +Newsgroups: comp.lang.misc,comp.lang.perl.misc,comp.lang.tcl,comp.lang.c,comp.lang.java,alt.lang.intercal,alt.test +Subject: Re: Readable Perl (was: Re: Relative Speed of Perl vs. Tcl vs. C) +Date: 27 Feb 1996 02:44:19 GMT +Organization: XS4ALL Internet +Message-ID: <4gtr64$s7h@news.xs4all.nl> +Summary: hit "n" now! quick! + +In article <4ge7bk$4vq@news.ox.ac.uk>, +David Hopwood wrote: +>In article <4gb3kp$lu7@gaia.ns.utk.edu>, +>Matthew B. Kennel wrote: +>>Randal L. Schwartz (merlyn@stonehenge.com) wrote: +>>: >>>>> "John" == John Viega writes: +>> +>>: John> People bitch about the readability of Perl non-stop. In fact, I have +>>: John> heard the joke, "Perl, the only language you can uuencode, and not +>>: John> notice" twice this week around the department. +>> +>>: OK, now which do you find most readable... +> +>This (Haskell): +> +>cancount n = "I can count to "++(show n)++"\n" +>concat (map cancount [1..10]) + +No, you got it all totally wrong. I think this is the best readable +(in Tri-INTERCAL): + +[Program moved to .3i file.] + +Now, I think the advantages of this are pretty clear. First, this is +clearly a write-only language. There are only few people insane enough +to actually understand the above drivel, and they wouldn't bother +touching your petty code, as they are too busy filling bathtubs with +brightly colored machine tools. + +Anyone else will simply be too scared to touch this code. So you can be +pretty sure nobody changes it behind your back. + +In fact, you can be pretty sure you won't change it either after you +wrote it, because you will probably have forgotten how the program +works 5 minutes after you wrote it. So any luser nagging for extra +features afterwards, is SOL. + +The other major advantage is... the above code took me about 3 hours +to write. Compare this to the 10 to 30 seconds it takes to write a +similar program in perl, BASIC, Haskell or what have you. But... that +means that when you programmed it in that other language, you'd have to +spend 2 hours 59 minutes and somewhere between 30 and 50 seconds +answering the phone talking to clueless lusers, changing backup tapes, +or doing other boring stuff. While you could have been programming +Intercal instead! Just think about that! + +And last, but certainly not least, is: the above code is likely to +impress your boss. Bosses are wont to be impressed by incomprehensible +things. They won't be impressed by a three line perl program that anyone +not wearing a diaper can understand. + +So that pretty much proves it. + +PS: this article contains some strange usage of the words "best readable" +that you probably weren't previously aware of :) + +-- +Jan-Pieter Cornet +Actual quote: "Linux was made by foreign terrorists to steal money from true + AMERICAN companies like Microsoft who invented computing as we + know it, and are being punished for their success..." +Linux -- "It's computing, Jim, but not as we know it" diff --git a/pit/delta.fft b/pit/delta.fft new file mode 100644 index 0000000..43eac5c --- /dev/null +++ b/pit/delta.fft @@ -0,0 +1,258 @@ +ONE +ONE TWO EIGHT +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +SIX OH OH OH OH OH OH ZERO ONE +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +SIX OH OH OH OH OH OH ZERO ONE +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO diff --git a/pit/fft.doc b/pit/fft.doc new file mode 100644 index 0000000..aff020f --- /dev/null +++ b/pit/fft.doc @@ -0,0 +1,55 @@ +The program fft.i provides a basic complex Fast Fourier Transform, +along with a simple write-in-read-out wrapper. This program requires +the floating-point library in lib/floatlib.i, which should be appended +to fft.i before compiling. + +The first number to enter specifies the direction of the transform. +Enter ONE to transform from time to frequency, or TWO for the inverse +transform. The second number to enter is the number of complex pairs. +This number must be a power of two, between TWO and THREE TWO SEVEN +SIX EIGHT inclusive. After this comes the actual data. Each entry must +consist of two floating-point numbers, the real value followed by the +imaginary value. + +After the data has been entered, the FFT is performed on it. When it +is completed, the resulting data will be output. The data is preceded +by I or II to indicate time or frequency data (i.e., the opposite of +the number input at the start), and a second integer giving the +number of pairs being output. + +Included are two files that produce simple curves when transformed. +delta.fft, the sum of two delta functions, transforms into a cosine +wave, and tophat.fft's output traces the sinc function. + +INTERCAL brings new meaning to the "fast" in Fast Fourier Transform. +On Muppetlabs' Pentium, 133MHz, a transform of 2048 data points takes +over 5 minutes of CPU time. + + +The actual FFT routine is at line label (100), and is self-contained +other than its dependence on the standard and floating-point +libraries, and a small subroutine described below. Its three arguments +are .9, .10, and ;1. .9 must contain #1 or #2 to select the forward or +inverse transform, respectively. .10 must contain the length of the +input data, and ;1 the data itself. ;1 must have the dimensions .10 BY +#2. No error checking is done on the parameters within the routine. +(The wrapper routine sanity-checks the user's input.) On exit, .9 will +contain #2 if it was #1 originally and vice versa, and ;1 will contain +the transformed data. + +The FFT algorithm was taken from "Numerical Recipes" (Press, et al; +Cambridge University Press, 1994 edition). For data centered on the +y-axis, it is usually best to cut the data in half at the axis and +switch their positions (i.e., enter the data for 0 to N/2 - 1 first, +followed by the data for -N/2 to -1) and then do the same with the +output. + +The FFT routine uses a subroutine, labelled (153), as a wrapper around +the multiplication routine (5030). This subroutine is an example of +how to handle errors as indicated by the .5 variable. + +Another noteworthy point is in the first part of the routine, where +the positions of the data are swapped with the bit-reversals of their +indices. Amazingly, bit-reversal is one of the few things that +INTERCAL can do more tersely than most other languages. It is nice to +see it actually finding a real-world application. diff --git a/pit/fft.i b/pit/fft.i new file mode 100644 index 0000000..d6d966b --- /dev/null +++ b/pit/fft.i @@ -0,0 +1,264 @@ + PLEASE WRITE IN .9 + DO .5 <- '?"'#65535~".9~#65532"'~#1"$#2'~#3 + DO (91) NEXT + DO .5 <- '?.&9$#2'~#3 + DO (91) NEXT + DO .5 <- '?"#3~.9"$#1'~#3 + DO (91) NEXT + PLEASE WRITE IN .10 + DO .5 <- '?"!10~.10'~#2"$#2'~#3 + DO (93) NEXT + DO .5 <- '?"'#65535~".10~#65534"'~#1"$#1'~#3 + DO (92) NEXT + PLEASE DO ;1 <- .10 BY #2 + DO .1 <- #1 + DO (10) NEXT +(11) DO (1001) NEXT +(10) PLEASE FORGET #1 + PLEASE WRITE IN :1 + DO (5090) NEXT + DO .5 <- '?".5~#2"$#2'~#3 + DO (94) NEXT + PLEASE DO ;1SUB.1#1 <- :2 + PLEASE WRITE IN :1 + DO (5090) NEXT + DO .5 <- '?".5~#2"$#2'~#3 + DO (94) NEXT + PLEASE DO ;1SUB.1#2 <- :2 + DO .5 <- '?".1~.10"$#1'~#3 + DO (1020) NEXT + DO (11) NEXT + PLEASE DO (100) NEXT + PLEASE READ OUT .9 + .10 + DO .1 <- #1 + DO (15) NEXT +(16) DO (1001) NEXT +(15) PLEASE FORGET #1 + DO :1 <- ;1SUB.1#1 + DO (5080) NEXT + PLEASE READ OUT :2 + DO :1 <- ;1SUB.1#2 + DO (5080) NEXT + PLEASE READ OUT :2 + DO .5 <- '?".1~.10"$#1'~#3 + DO (1020) NEXT + DO (16) NEXT + PLEASE GIVE UP + +(91) DO (1001) NEXT + PLEASE ENTER ONE OR TWO TO SPECIFY THE TRANSFORM. +(92) DO (1001) NEXT + DO YOU REALLY WANT TO TRANSFORM A VECTOR OF ONE NUMBER? +(93) DO (1001) NEXT + DOES "POWER OF TWO" MEAN ANYTHING TO YOU? +(94) DO (1001) NEXT + DOCUMENTATION EXISTS. MAYBE YOU SHOULD READ IT. + PLEASE DON'T GIVE UP + +(100) PLEASE STASH .1 + .2 + .3 + .4 + .5 + .6 + .7 + :1 + :2 + + :3 + :4 + :5 + :6 + :7 + .11 + :10 + :11 + :12 + :13 + DO .11 <- #32768 + DO .1 <- #1 + DO .2 <- .10~#65532 + DO (101) NEXT +(102) DO (1001) NEXT + PLEASE DO .11 <- .V11 + DO (1020) NEXT + DO .2 <- .2~#65534 +(101) PLEASE FORGET #1 + DO .5 <- '?".2~.2"$#2'~#3 + DO (102) NEXT + PLEASE STASH .1 + DO .1 <- #1 + DO .2 <- #1 + DO (105) NEXT +(106) DO (1001) NEXT +(105) PLEASE FORGET #1 + DO .5 <- '?.1$.2'~'#0$#65535' + DO .5 <- '?"!2~.5'~'"?.5~.5"~#32767'"$#1'~#3 + DO (107) NEXT + PLEASE DO :1 <- ;1SUB.1#1 + DO ;1SUB.1#1 <- ;1SUB.2#1 + DO ;1SUB.2#1 <- :1 + PLEASE DO :1 <- ;1SUB.1#2 + DO ;1SUB.1#2 <- ;1SUB.2#2 + DO ;1SUB.2#2 <- :1 + DO (108) NEXT +(107) DO (1001) NEXT +(108) PLEASE FORGET #1 + DO .5 <- .1 + DO .1 <- !1~#255'$!1~#65280' + DO .1 <- !1~#255'$!1~#65280' + DO .1 <- !1~#255'$!1~#65280' + DO .1 <- !1~#255'$!1~#65280' + DO .1 <- .1~.11 + DO (1020) NEXT + DO .2 <- .1 + DO .1 <- .5 + DO (1020) NEXT + DO .5 <- '?".1~.10"$#1'~#3 + DO (106) NEXT + DO .6 <- #1 + PLEASE DO :7 <- '"'V.9~#2'$#571"~"#32768$#32767"'$#35133 + DO (110) NEXT +(111) DO (1001) NEXT +(110) PLEASE FORGET #1 + DO .7 <- !6$#0'~'#32767$#1' + DO :1 <- :7 + PLEASE DO (5200) NEXT + DO :13 <- :2 + PLEASE DO :2 <- #63488$#61440 + DO (1509) NEXT + DO :7 <- :3 + DO :1 <- :3 + PLEASE DO (5200) NEXT + DO :1 <- :2 + PLEASE DO (530) NEXT + DO :1 <- :3 + PLEASE DO :2 <- #34816$#0 + PLEASE DO (1509) NEXT + DO :12 <- :3 + DO :11 <- #0 + PLEASE DO :10 <- #30720$#28672 + DO .1 <- #1 + DO (120) NEXT +(120) PLEASE FORGET #1 + DO .4 <- .1 + DO (130) NEXT +(131) DO (1001) NEXT +(130) PLEASE FORGET #1 + DO .2 <- .6 + DO (1000) NEXT + PLEASE DON'T GIVE UP + DO :1 <- :10 + DO :2 <- ;1SUB.3#1 + PLEASE DO (530) NEXT + DO :4 <- :3 + DO :1 <- :11 + DO :2 <- ;1SUB.3#2 + PLEASE DO (530) NEXT + DO :1 <- :4 + DO :2 <- :3 + PLEASE DO (5010) NEXT + DO :5 <- :3 + DO :1 <- :10 + DO :2 <- ;1SUB.3#2 + PLEASE DO (530) NEXT + DO :4 <- :3 + DO :1 <- :11 + DO :2 <- ;1SUB.3#1 + PLEASE DO (530) NEXT + DO :1 <- :4 + DO :2 <- :3 + PLEASE DO (5000) NEXT + DO :6 <- :3 + DO :1 <- ;1SUB.1#1 + DO :2 <- :5 + PLEASE DO (5010) NEXT + PLEASE DO ;1SUB.3#1 <- :3 + DO :1 <- ;1SUB.1#2 + DO :2 <- :6 + PLEASE DO (5010) NEXT + PLEASE DO ;1SUB.3#2 <- :3 + DO :1 <- ;1SUB.1#1 + DO :2 <- :5 + PLEASE DO (5000) NEXT + PLEASE DO ;1SUB.1#1 <- :3 + DO :1 <- ;1SUB.1#2 + DO :2 <- :6 + PLEASE DO (5000) NEXT + PLEASE DO ;1SUB.1#2 <- :3 + DO .2 <- .7 + DO (1000) NEXT + DO .1 <- .3 + DO .5 <- '?.1$.10'~'#0$#65535' + DO .5 <- '?"!1~.5'~'"?.5~.5"~#32767'"$#1'~#3 + DO (131) NEXT + DO :1 <- :10 + DO :2 <- :12 + PLEASE DO (530) NEXT + DO :4 <- :3 + DO :1 <- :11 + DO :2 <- :13 + PLEASE DO (530) NEXT + DO :1 <- :10 + DO :2 <- :3 + PLEASE DO (5010) NEXT + DO :1 <- :3 + DO :2 <- :4 + PLEASE DO (5000) NEXT + DO :1 <- :10 + DO :2 <- :13 + PLEASE DO :10 <- :3 + PLEASE DO (530) NEXT + DO :4 <- :3 + DO :1 <- :11 + DO :2 <- :12 + PLEASE DO (530) NEXT + DO :1 <- :11 + DO :2 <- :3 + PLEASE DO (5000) NEXT + DO :1 <- :3 + DO :2 <- :4 + PLEASE DO (5000) NEXT + DO :11 <- :3 + DO .5 <- '?".4~.6"$#2'~#3 + DO (121) NEXT + DO .1 <- .4 + DO (1020) NEXT + DO (120) NEXT +(121) DO (1001) NEXT + PLEASE FORGET #1 + DO .6 <- .7 + DO .5 <- '?".6~.10"$#1'~#3 + DO (111) NEXT + PLEASE RETRIEVE .1 + DO .5 <- .9 + DO (140) NEXT + DO .1 <- '?.1$#65535'~'#0$#65535' + DO (1020) NEXT + DO :2 <- '"'"'"!1$#0'~'#511$#1'"$#0'~'#1023$#3'"$#0'~'#4095$ + #15'"$#0'~'#65535$#31' + DO :2 <- ':2~"#31$#2047"'$':2~"#1023$#63"' + DO .1 <- #1 + DO (145) NEXT +(145) PLEASE FORGET #1 + DO :1 <- ;1SUB.1#1 + DO .5 <- '?"':1~":1~'#32767$#65535'"'~#1"$#1'~#3 + DO (146) NEXT + PLEASE DO (1509) NEXT + DO ;1SUB.1#1 <- :3 + DO (147) NEXT +(146) DO (1001) NEXT +(147) PLEASE FORGET #1 + DO :1 <- ;1SUB.1#2 + DO .5 <- '?"':1~":1~'#32767$#65535'"'~#1"$#1'~#3 + DO (148) NEXT + PLEASE DO (1509) NEXT + DO ;1SUB.1#2 <- :3 + DO (149) NEXT +(148) DO (1001) NEXT +(149) PLEASE FORGET #1 + DO .5 <- '?".1~.10"$#2'~#3 + DO (140) NEXT + DO (1020) NEXT + DO (145) NEXT +(140) DO (1001) NEXT +(141) PLEASE FORGET #1 + DO .9 <- !9~#1'$!9~#2' + PLEASE RETRIEVE .1 + .2 + .3 + .4 + .5 + .6 + .7 + :1 + :2 + + :3 + :4 + :5 + :6 + :7 + .11 + :10 + :11 + :12 + :13 + PLEASE RESUME #1 + +(530) DO (5030) NEXT + DO (531) NEXT + DO :3 <- '"':3~"#65535$#0"'$#32767"~"#32768$#32767"'$#65535 + PLEASE RESUME #1 +(531) DO (532) NEXT + DO :3 <- '"':3~"#65535$#0"'$':3~"#2047$#0"'"~"#32768$#32767"'$ + ':3~"#0$#4095"' + PLEASE RESUME #2 +(532) DO (1001) NEXT + PLEASE RESUME #3 + + PLEASE APPEND THE FLOATING-POINT LIBRARY ROUTINES diff --git a/pit/flonck.doc b/pit/flonck.doc new file mode 100644 index 0000000..8616bc9 --- /dev/null +++ b/pit/flonck.doc @@ -0,0 +1,61 @@ +Flonck, short for FLOating-point Numerical Calculator, is an INTERCAL +version of the classic reverse-polish calculator. All values are +entered and displayed as floating-point numbers. Entering a number +adds it to the top of the stack. The various operations are indicated +by integer number, and take their argument(s) off the top of the stack +and replace it/them with the result. Besides the main stack, flonck +also includes two separate "registers". + +Note that this program requires the floating-point library in +lib/floatlib.i, which should be appended to flonck.i before compiling. + +Here is the quick-reference chart of available operations: + + ONE OH change sign TWO OH store in M +ONE add ONE ONE invert TWO ONE add to M +TWO subtract ONE TWO square root TWO TWO push M +THREE multiply ONE THREE ln TWO THREE exchange M +FOUR divide ONE FOUR exp TWO FOUR print M +FIVE remainder ONE FIVE x^y TWO FIVE store in N +SIX print ONE SIX pop TWO SIX add to N +SEVEN print all ONE SEVEN clear all TWO SEVEN push N +EIGHT duplicate ONE EIGHT int TWO EIGHT exchange N +NINE twiddle ONE NINE random TWO NINE print N + THREE OH quit + +Functions ONE through FIVE should be self-explanatory. SIX displays +the topmost number on the stack without removing it. SEVEN displays +the entire stack, from top to bottom, again without changing anything. +EIGHT duplicates the topmost number, pushing an extra copy of it. NINE +causes the top two numbers on the stack to switch places. + +The next few functions should be familiar to anyone who's used a +pocket calculator in recent memory. ONE OH multiplies the topmost +number by -1. ONE ONE divides the topmost number into 1. ONE TWO is +the square root function, ONE THREE is the natural logarithm function, +and ONE FOUR is the exponential function. ONE FIVE raises the topmost +number to the power of the next-topmost number. ONE SIX throws away +the topmost number, never to be seen again. ONE SEVEN wipes out the +entire stack and starts afresh. ONE EIGHT chops off the fractional +part of the topmost number. ONE NINE causes a randomly chosen number +between 0 and 1 to be added to the top of the stack. + +The twenties are the functions that manipulate the two registers, +named M and N. (Both registers start out initialized to zero.) TWO OH +takes the topmost number off of the stack and stores it in M. TWO ONE +takes the topmost number off of the stack and adds it to whatever is +already in M. TWO TWO makes a copy of whatever is in M and adds it to +the top of the stack. TWO THREE swaps the contents of M with the +topmost number on the stack. TWO FOUR displays the contents of M +without changing it. Functions TWO FIVE through TWO NINE repeat the +above five functionalities for the register N. + +And finally, as you might have guessed, writing (in) THREE OH causes +flonck to come to an end. + +If an input does not correspond to a floating-point number or an +instruction, or if a function is input that requires more numbers on +the stack than currently exist, or if a function overflows or returns +an error, flonck prints out an error message, namely "XXX", and +continues. Note that in the latter case, the values used as function +arguments will still be removed from the stack. diff --git a/pit/flonck.i b/pit/flonck.i new file mode 100644 index 0000000..4c262bc --- /dev/null +++ b/pit/flonck.i @@ -0,0 +1,277 @@ + DO :321 <- #0 + DO :322 <- #0 + DO :123 <- #65535$#65535 + PLEASE STASH :123 + DO (1) NEXT + +(1) PLEASE FORGET #1 + PLEASE WRITE IN :1 + DO .5 <- '?"':1~:1'~#1"$#2'~#3 + DO (11) NEXT + DO :123 <- #0 + PLEASE STASH :123 + DO (1) NEXT +(11) DO (1001) NEXT + DO .5 <- :1~'#65280$#65280' + DO .5 <- '?"!5~.5'~#1"$#1'~#3 + DO (10) NEXT + PLEASE FORGET #1 + DO (5090) NEXT + DO .5 <- '?".5~#2"$#2'~#3 + DO (19) NEXT + DO :123 <- :2 + PLEASE STASH :123 + DO (1) NEXT +(10) DO (1001) NEXT + PLEASE FORGET #2 + DO .5 <- '?"':1~#65504'~#1"$#2'~#3 + DO (19) NEXT + DO (131) NEXT + +(131) DO (130) NEXT + PLEASE FORGET #1 + DO (18) NEXT +(130) DO (129) NEXT + PLEASE GIVE UP +(129) DO (128) NEXT + PLEASE FORGET #3 + DO :1 <- :322 + DO (5080) NEXT + PLEASE READ OUT :2 + DO (1) NEXT +(128) DO (127) NEXT + PLEASE FORGET #4 + DO (22) NEXT + DO :123 <- :322 + PLEASE STASH :123 + DO :322 <- :2 + DO (1) NEXT +(127) DO (126) NEXT + PLEASE FORGET #5 + DO :123 <- :322 + PLEASE STASH :123 + DO (1) NEXT +(126) DO (125) NEXT + PLEASE FORGET #6 + DO (21) NEXT + DO :2 <- :322 + DO (5000) NEXT + DO (33) NEXT + PLEASE RETRIEVE :123 + DO :322 <- :123 + DO (1) NEXT +(125) DO (124) NEXT + PLEASE FORGET #7 + DO (22) NEXT + DO :322 <- :2 + DO (1) NEXT +(124) DO (123) NEXT + PLEASE FORGET #8 + DO :1 <- :321 + DO (5080) NEXT + PLEASE READ OUT :2 + DO (1) NEXT +(123) DO (122) NEXT + PLEASE FORGET #9 + DO (21) NEXT + DO :123 <- :321 + PLEASE STASH :123 + DO :321 <- :1 + DO (1) NEXT +(122) DO (121) NEXT + PLEASE FORGET #10 + DO :123 <- :321 + PLEASE STASH :123 + DO (1) NEXT +(121) DO (120) NEXT + PLEASE FORGET #11 + DO (22) NEXT + DO :1 <- :321 + DO (5000) NEXT + DO (33) NEXT + PLEASE RETRIEVE :123 + DO :321 <- :123 + DO (1) NEXT +(120) DO (119) NEXT + PLEASE FORGET #12 + DO (21) NEXT + DO :321 <- :1 + DO (1) NEXT +(119) DO (118) NEXT + PLEASE FORGET #13 + DO (5400) NEXT + DO :123 <- :1 + PLEASE STASH :123 + DO (1) NEXT +(118) DO (117) NEXT + PLEASE FORGET #14 + DO (21) NEXT + DO (5020) NEXT + DO :123 <- :2 + PLEASE STASH :123 + DO (1) NEXT +(117) DO (116) NEXT + PLEASE FORGET #15 + DO (271) NEXT +(272) DO (1001) NEXT +(271) PLEASE FORGET #1 + PLEASE RETRIEVE :123 + DO .5 <- '?"':123~:123'~'#32768$#0'"$#1'~#3 + DO (272) NEXT + PLEASE STASH :123 + DO (1) NEXT +(116) DO (115) NEXT + PLEASE FORGET #16 + DO (21) NEXT + DO (1) NEXT +(115) DO (114) NEXT + PLEASE FORGET #17 + DO (22) NEXT + DO (21) NEXT + DO (5130) NEXT + DO (33) NEXT + DO (1) NEXT +(114) DO (113) NEXT + PLEASE FORGET #18 + DO (21) NEXT + DO (5120) NEXT + DO (32) NEXT + DO (1) NEXT +(113) DO (112) NEXT + PLEASE FORGET #19 + DO (21) NEXT + DO (5110) NEXT + DO (32) NEXT + DO (1) NEXT +(112) DO (111) NEXT + PLEASE FORGET #20 + DO (21) NEXT + DO (5100) NEXT + DO (32) NEXT + DO (1) NEXT +(111) DO (110) NEXT + PLEASE FORGET #21 + DO (22) NEXT + DO :1 <- #30720$#28672 + DO (5040) NEXT + DO (33) NEXT + DO (1) NEXT +(110) DO (109) NEXT + PLEASE FORGET #22 + DO (21) NEXT + PLEASE DO :123 <- '"?':123~"#65535$#0"'$#32768"~"#0$#65535"'$ + ':123~"#0$#65535"' + PLEASE STASH :123 + DO (1) NEXT +(109) DO (108) NEXT + PLEASE FORGET #23 + DO (21) NEXT + DO (22) NEXT + DO :123 <- :1 + PLEASE STASH :123 + DO :123 <- :2 + PLEASE STASH :123 + DO (1) NEXT +(108) DO (107) NEXT + PLEASE FORGET #24 + DO (21) NEXT + PLEASE STASH :123 + :123 + DO (1) NEXT +(107) DO (106) NEXT + PLEASE FORGET #25 + DO :1 <- #65535$#65535 + DO (171) NEXT +(171) PLEASE FORGET #1 + PLEASE STASH :1 + PLEASE RETRIEVE :123 + DO .5 <- '?"':123~:123'~'#32768$#0'"$#2'~#3 + DO (172) NEXT + DO :1 <- :123 + DO (5080) NEXT + PLEASE READ OUT :2 + DO (171) NEXT +(172) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE STASH :123 + PLEASE RETRIEVE :1 + DO :123 <- :1 + DO .5 <- '?"':1~:1'~'#32768$#0'"$#1'~#3 + DO (172) NEXT + DO (1) NEXT +(106) DO (105) NEXT + PLEASE FORGET #26 + DO (21) NEXT + PLEASE STASH :123 + DO (5080) NEXT + PLEASE READ OUT :2 + DO (1) NEXT +(105) DO (104) NEXT + PLEASE FORGET #27 + DO (22) NEXT + DO (21) NEXT + DO (5050) NEXT + DO (33) NEXT + DO (1) NEXT +(104) DO (103) NEXT + PLEASE FORGET #28 + DO (22) NEXT + DO (21) NEXT + DO (5040) NEXT + DO (33) NEXT + DO (1) NEXT +(103) DO (102) NEXT + PLEASE FORGET #29 + DO (22) NEXT + DO (21) NEXT + DO (5030) NEXT + DO (33) NEXT + DO (1) NEXT +(102) DO (101) NEXT + PLEASE FORGET #30 + DO (22) NEXT + DO (21) NEXT + DO (5010) NEXT + DO (33) NEXT + DO (1) NEXT +(101) DO (100) NEXT + PLEASE FORGET #31 + DO (22) NEXT + DO (21) NEXT + DO (5000) NEXT + DO (33) NEXT + DO (1) NEXT + +(100) PLEASE RESUME :1 + +(19) DO (1001) NEXT +(18) PLEASE READ OUT #30 + PLEASE FORGET #1 + DO (1) NEXT + +(21) PLEASE RETRIEVE :123 + DO :1 <- :123 + DO .5 <- '?"':1~:1'~'#32768$#0'"$#2'~#3 + DO (1001) NEXT + PLEASE FORGET #2 + DO (18) NEXT + +(22) PLEASE RETRIEVE :123 + DO :2 <- :123 + DO .5 <- '?"':2~:2'~'#32768$#0'"$#2'~#3 + DO (1001) NEXT + PLEASE FORGET #2 + DO (18) NEXT + +(32) DO :3 <- :2 +(33) DO :123 <- :3 + DO (35) NEXT + PLEASE FORGET #1 + DO (18) NEXT +(35) DO (36) NEXT + DO :123 <- #0 + DO (37) NEXT +(36) DO (1001) NEXT +(37) PLEASE STASH :123 + PLEASE RESUME #3 + + PLEASE APPEND THE FLOATING-POINT LIBRARY ROUTINES diff --git a/pit/hail_mary.doc b/pit/hail_mary.doc new file mode 100644 index 0000000..bbfdd54 --- /dev/null +++ b/pit/hail_mary.doc @@ -0,0 +1,56 @@ + +From: cornet@OTech.fgg.EUR.nl (Jan-Pieter Cornet) +Newsgroups: alt.folklore.computers,alt.lang.intercal +Subject: Re: 90% Cobol?!? +Date: 30 Sep 1994 12:03:23 +0100 +Organization: Education Technology, Erasmus University, Rotterdam, The Netherlands +Message-ID: <36gr9r$k4i@gaia.otech.fgg.eur.nl> + +[note -- alt.lang.intercal added to newsgroups line. rec.humor removed. +no longer necessary, the added group is also a humor group :] + +In article <36evl6$e3m@fenris.hiof.no>, +Gunnar Horrigmo wrote: +>Once upon a time Adam Felson scribbled: +>>>Forgive me father for I have programmed in COBOL. +>>>>You are forgiven. Go now and sin no more. +>>>Thank you father. Whats that? 1,000,000 Hail Mary's? +>>>[COBOL 1,000,000 Hail-Mary's removed] +>>FORTH: +> +>>: 1,000,000_hail_mary's @ special characters in word defined +>> 1000 0 DO @ FORTH usually has a 16bit data stack +>> 1000 0 DO +>> hail-mary! +>> LOOP +>> LOOP +>>; +> +>Ok. I'll have a go at ML, since I'm trying to learn that anyway... +> +> function Hail_Mary (int i) +> if i < 1000000 then Hail_Mary(i+1) +> +>Probably way off, but I've just started, so please correct me. + +Fine. You've asked for it, you'll get it. Here it is, 1,000,000 Hail-Mary's +in TriIntercal, which is of course a much better language for this +than ML. + +BTW, there appears to be an anomaly in READING OUT tail variables, since +the READ OUT does a bit reversal instead of (as one might expect in +TriIntercal) a trit reversal. + +Helpful hint: before you run this through ick, change the loop constants +to something sensible. Finding the loop constants is left as an exercise +to the reader :) + +Helpful hint 2: This would not very likely be a winning ICICC entry :) + +[program moved to separate file] + +Have fun, + +-- +Jan-Pieter Cornet + diff --git a/pit/hello.i b/pit/hello.i new file mode 100644 index 0000000..e40efa7 --- /dev/null +++ b/pit/hello.i @@ -0,0 +1,16 @@ + DO ,1 <- #13 + PLEASE DO ,1SUB#1 <- #234 + DO ,1SUB#2 <- #112 + DO ,1SUB#3 <- #112 + DO ,1SUB#4 <- #0 + DO ,1SUB#5 <- #64 + DO ,1SUB#6 <- #194 + DO ,1SUB#7 <- #48 + PLEASE DO ,1SUB#8 <- #22 + DO ,1SUB#9 <- #248 + DO ,1SUB#10 <- #168 + DO ,1SUB#11 <- #24 + DO ,1SUB#12 <- #16 + DO ,1SUB#13 <- #214 + PLEASE READ OUT ,1 + PLEASE GIVE UP diff --git a/pit/iching.doc b/pit/iching.doc new file mode 100644 index 0000000..cdb8edc --- /dev/null +++ b/pit/iching.doc @@ -0,0 +1,21 @@ + +Notes on iching1.i and iching2.i: + +Both versions (1 and 2) use the same code for generating lines of the +hexagram, a simulation of the "coin oracle" method. (Six separate +unconditional calls to (1020) were used since I thought lumping them +all together by starting .1 at #6 would be disrespectful.) +Implementation of the yarrow-stalk oracle is left as an exercise for +the student. Note that in converting the numbers from the program into +the lines of a hexagram, one should work from the bottom up. The last +number gives the top line. + +The traditional sequence of the hexagrams does not have a consistent +mathematical explanation. Version 2 of the program therefore uses a +lookup table to determine the number of each hexagram in sequence. The +six lines are printed as in version 1, then the sequence number for the +hexagram, and finally the sequence number for the derived hexagram +obtained by replacing moving lines (9 and 6) by their opposites. + +Louis Howell +September 10, 1996 diff --git a/pit/iching1.i b/pit/iching1.i new file mode 100644 index 0000000..2701822 --- /dev/null +++ b/pit/iching1.i @@ -0,0 +1,19 @@ + DO .2 <- #32 + PLEASE COME FROM (10) + DO .1 <- #0 + DO (1020) NEXT + DO (1020) NEXT + PLEASE DO %50 (1020) NEXT + DO (1020) NEXT + DO (1020) NEXT + PLEASE DO %50 (1020) NEXT + DO (1020) NEXT + DO (1020) NEXT + PLEASE DO %50 (1020) NEXT + DO READ OUT .1 + DO (30) NEXT +(10) DO .2 <- .2~#62 +(20) DO RESUME "?.2$#2"~#3 +(30) DO (20) NEXT + PLEASE FORGET #1 + PLEASE GIVE UP diff --git a/pit/iching2.i b/pit/iching2.i new file mode 100644 index 0000000..b37d1eb --- /dev/null +++ b/pit/iching2.i @@ -0,0 +1,114 @@ + DO .2 <- #32 + DO .5 <- #0 + DO .6 <- #0 + PLEASE COME FROM (10) + DO .1 <- #0 + DO (1020) NEXT + DO (1020) NEXT + PLEASE DO %50 (1020) NEXT + DO (1020) NEXT + DO (1020) NEXT + PLEASE DO %50 (1020) NEXT + DO (1020) NEXT + DO (1020) NEXT + PLEASE DO %50 (1020) NEXT + DO READ OUT .1 + DO (61) NEXT + DO .6 <- "V.2$.6"~#1365 + DO (93) NEXT +(62) DO .3 <- "?.1$#6"~#21 + PLEASE RESUME '?"!3~.3'~#1"$#2'~#3 +(61) DO (62) NEXT + PLEASE FORGET #1 + DO (71) NEXT + DO .5 <- "V.2$.5"~#1365 + DO .6 <- "V.2$.6"~#1365 + DO (93) NEXT +(72) DO .3 <- "?.1$#7"~#21 + PLEASE RESUME '?"!3~.3'~#1"$#2'~#3 +(71) DO (72) NEXT + PLEASE FORGET #1 + DO (91) NEXT + DO .5 <- "V.2$.5"~#1365 + DO (93) NEXT +(92) DO .3 <- "?.1$#9"~#85 + PLEASE RESUME '?"!3~.3'~#1"$#2'~#3 +(91) DO (92) NEXT +(93) PLEASE FORGET #1 + DO (30) NEXT +(10) DO .2 <- .2~#62 +(20) DO RESUME "?.2$#2"~#3 +(30) DO (20) NEXT + PLEASE FORGET #1 + DO ,1 <- #64 + DO ,1 SUB #1 <- #2 + DO ,1 SUB #2 <- #23 + DO ,1 SUB #3 <- #8 + PLEASE DO ,1 SUB #4 <- #20 + DO ,1 SUB #5 <- #16 + DO ,1 SUB #6 <- #35 + DO ,1 SUB #7 <- #45 + PLEASE DO ,1 SUB #8 <- #12 + DO ,1 SUB #9 <- #15 + DO ,1 SUB #10 <- #52 + DO ,1 SUB #11 <- #39 + PLEASE DO ,1 SUB #12 <- #53 + DO ,1 SUB #13 <- #62 + DO ,1 SUB #14 <- #56 + DO ,1 SUB #15 <- #31 + PLEASE DO ,1 SUB #16 <- #33 + DO ,1 SUB #17 <- #7 + DO ,1 SUB #18 <- #4 + DO ,1 SUB #19 <- #29 + PLEASE DO ,1 SUB #20 <- #59 + DO ,1 SUB #21 <- #40 + DO ,1 SUB #22 <- #64 + DO ,1 SUB #23 <- #47 + PLEASE DO ,1 SUB #24 <- #6 + DO ,1 SUB #25 <- #46 + DO ,1 SUB #26 <- #18 + DO ,1 SUB #27 <- #48 + PLEASE DO ,1 SUB #28 <- #57 + DO ,1 SUB #29 <- #32 + DO ,1 SUB #30 <- #50 + DO ,1 SUB #31 <- #28 + PLEASE DO ,1 SUB #32 <- #44 + DO ,1 SUB #33 <- #24 + DO ,1 SUB #34 <- #27 + DO ,1 SUB #35 <- #3 + PLEASE DO ,1 SUB #36 <- #42 + DO ,1 SUB #37 <- #51 + DO ,1 SUB #38 <- #21 + DO ,1 SUB #39 <- #17 + PLEASE DO ,1 SUB #40 <- #25 + DO ,1 SUB #41 <- #36 + DO ,1 SUB #42 <- #22 + DO ,1 SUB #43 <- #63 + PLEASE DO ,1 SUB #44 <- #37 + DO ,1 SUB #45 <- #55 + DO ,1 SUB #46 <- #30 + DO ,1 SUB #47 <- #49 + PLEASE DO ,1 SUB #48 <- #13 + DO ,1 SUB #49 <- #19 + DO ,1 SUB #50 <- #41 + DO ,1 SUB #51 <- #60 + PLEASE DO ,1 SUB #52 <- #61 + DO ,1 SUB #53 <- #54 + DO ,1 SUB #54 <- #38 + DO ,1 SUB #55 <- #58 + PLEASE DO ,1 SUB #56 <- #10 + DO ,1 SUB #57 <- #11 + DO ,1 SUB #58 <- #26 + DO ,1 SUB #59 <- #5 + PLEASE DO ,1 SUB #60 <- #9 + DO ,1 SUB #61 <- #34 + DO ,1 SUB #62 <- #14 + DO ,1 SUB #63 <- #43 + PLEASE DO ,1 SUB #64 <- #1 + DO .1 <- .5 + DO (1020) NEXT + PLEASE READ OUT ,1 SUB .1 + DO .1 <- .6 + DO (1020) NEXT + PLEASE READ OUT ,1 SUB .1 + PLEASE GIVE UP diff --git a/pit/ins.doc b/pit/ins.doc new file mode 100644 index 0000000..8fa329e --- /dev/null +++ b/pit/ins.doc @@ -0,0 +1,132 @@ +"Intersections & Splats" is an INTERCAL implementation of one of my +favorite games, "Cows & Bulls," now more commonly known by the +commercial version, "Mastermind." + + Rules of the Game + +The idea of the game is that one person selects a "code" in the form +of a short string of digits, typically four. ("Mastermind" used colors +in place of numbers.) The other person has a limited number of chances +to guess what the code is. Every move consists of submitting a guess, +and the first player replying with a score. Each scoring reveals a +little more information about the code. A guess is scored by giving a +certain number of cows and a certain number of bulls. These correspond +to Mastermind's white pegs and black pegs, respectively - and, in this +program, intersections (+) and splats (*). + +This game is perfect for a computer because the person who makes the +code has nothing to do but score the other player's guesses - a +mechanical task. + +Here's how the scoring works. For every number in the code that is +matched by the same number in the same position in the guess, a splat +is scored. And for every number in the code that is matched by the +same number in the guess, but in the wrong position, an intersection, +is scored. + +For example: with a code of "3451" and a guess of "2465", one splat +and one intersection would be earned. The splat is for the 4, and the +intersection is for the 5. Of course, the player making the guesses +isn't told which numbers earned what - that's what they have to +deduce. A guess of "6152" gets exactly the same score, even though the +intersection and splat correspond to completely different digits. + +The game continues until the code is discovered or the player runs out +of guesses. + +Note that there can be some confusion about how the scoring works with +repeated digits. In absence of a better standards body, I have stuck +with the version described in the Mastermind rules, which is that a +digit in the guess can match up with more than one digit in the code. +Another example is in order. Say the code is "2412". A guess of "2544" +would earn one splat and two intersections. The splat is for having a +2 in the guess in the right position, and one of the intersections is +also for having a 2 in the guess, but now in the wrong position. The +final intersection is earned by having a 4 in the guess, again in the +wrong position. The second 4 in the guess, however, does not affect +the scoring. + +Here is an algorithmic description of how scoring is done. The player +looks at each digit in the code in turn. If the digit under +consideration is matched by the same digit in the same place, a splat +is earned. Otherwise, if any other digit in the guess is the same, an +intersection is earned. + +For those conversant in C, here is an even more algorithmic +description: + + for (i = 0 ; i < digits ; ++i) + if (guess[i] == code[i]) + ++splats; + else + for (j = 0 ; j < digits ; ++j) + if (guess[j] == code[i]) { + ++intersections; + break; + } + +For those conversant in INTERCAL, consult the source code. + +Anyway, enough of this. Play the game a few times; you'll get the idea. + + How To Play + +At each move the board is displayed, which shows you all of your +previous guesses. Above each guess are the intersections and splats +that they earned. Here is an example of a game in progress: + + + + * + + * * + (1) (5) (2) ( ) ( ) ( ) ( ) ( ) ( ) ( ) (?) + (2) (4) (4) ( ) ( ) ( ) ( ) ( ) ( ) ( ) (?) + (4) (4) (3) ( ) ( ) ( ) ( ) ( ) ( ) ( ) (?) + (2) (6) (5) ( ) ( ) ( ) ( ) ( ) ( ) ( ) (?) + +The first guess "1242" earned one splat and one intersection. The +third guess "2435" earned two splats and one intersection. The player +has seven more guesses left. Guesses are typed in at the "MOVE:" +prompt. + +At the end of the game, the questions marks at the right are replaced +with the code. You are then prompted with "[CNQ]". Enter N to start a +new game, Q to quit playing, or C to configure the game (see below). N +is the default, so if you just hit enter, or type anything except C or +Q, it has the same effect. You can also use any of these commands at +the "MOVE:" prompt, if you wish to abandon the current game. In +addition, R can be entered during a game to redraw the board. + + Configuring the Game + +The game is set up originally to have ten guesses in a game, four +digits in the code, and to use the digits 1 through 6. (This matches +the setup of the "Mastermind" game.) The C command can be used to +modify these settings, so as to change the difficulty of the game. + +When you enter the C command, you are first prompted for the X +setting, the number of guesses allowed; then the Y setting, which is +the number of digits in the code; and finally the N setting, the +number of digits used in the game. Each number is entered using +standard INTERCAL numeric entry. (Yes, I could have used my own numio +routines here, but the program is big enough as it is. Besides, I +didn't want you to completely forget that you were using an INTERCAL +program.) You can enter ZERO at any three prompts to abort the +configuration and return to the current game. If any values are higher +than ONE FIVE, the value modulo 16 will be used instead. Note that +while you can enter a value higher than NINE for the number of digits, +you may need to have an ASCII chart handy. (By the way, if anyone +wants an EBCDIC version, drop me a line.) + + Other Versions + +I enjoyed writing this program so much, that I created two others +based on it. First, there is a colorized version, which requires a +VT100/ANSI color terminal, or something compatible. And second, there +is a CGI script version that plays this game. A package containing all +three versions is available at ftp.muppetlabs.com under +/pub/intercal/ins.tar.gz. In addition, you can play the CGI script at +http://www.muppetlabs.com/~breadbox/intercal/ins/insstart.html. + + Coda + +That's it. Have fun. Questions, comments, and concerns for my mental +health can be directed to breadbox@muppetlabs.com. diff --git a/pit/ins.i b/pit/ins.i new file mode 100644 index 0000000..0915e71 --- /dev/null +++ b/pit/ins.i @@ -0,0 +1,475 @@ + PLEASE NOTE THE STARTUP BANNER + + PLEASE DO ,1 <- #43 + DO ,1SUB#1 <- #176 + DO ,1SUB#2 <- #190 + DO ,1SUB#3 <- #142 + DO ,1SUB#4 <- #146 + DO ,1SUB#5 <- #110 + DO ,1SUB#6 <- #218 + DO ,1SUB#7 <- #38 + DO ,1SUB#8 <- #98 + DO ,1SUB#9 <- #158 + DO ,1SUB#10 <- #186 + DO ,1SUB#11 <- #70 + DO ,1SUB#12 <- #58 + DO ,1SUB#13 <- #198 + DO ,1SUB#14 <- #98 + DO ,1SUB#15 <- #158 + DO ,1SUB#16 <- #66 + DO ,1SUB#17 <- #190 + DO ,1SUB#18 <- #218 + DO ,1SUB#19 <- #38 + DO ,1SUB#20 <- #114 + DO ,1SUB#21 <- #142 + DO ,1SUB#22 <- #18 + DO ,1SUB#23 <- #238 + DO ,1SUB#24 <- #146 + DO ,1SUB#25 <- #110 + DO ,1SUB#26 <- #58 + DO ,1SUB#27 <- #198 + DO ,1SUB#28 <- #0 + DO ,1SUB#29 <- #160 + DO ,1SUB#30 <- #96 + DO ,1SUB#31 <- #0 + DO ,1SUB#32 <- #58 + DO ,1SUB#33 <- #198 + DO ,1SUB#34 <- #250 + DO ,1SUB#35 <- #6 + DO ,1SUB#36 <- #210 + DO ,1SUB#37 <- #46 + DO ,1SUB#38 <- #130 + DO ,1SUB#39 <- #126 + DO ,1SUB#40 <- #218 + DO ,1SUB#41 <- #38 + DO ,1SUB#42 <- #58 + DO ,1SUB#43 <- #122 + PLEASE READ OUT ,1 + + PLEASE NOTE THE INITIALIZATION OF GLOBAL VALUES + + PLEASE DO ,5 <- #1 + DO ,5SUB#1 <- #0 + PLEASE DO ,6 <- #1 + DO ,6SUB#1 <- #76 + PLEASE DO ,7 <- #1 + DO ,7SUB#1 <- #180 + PLEASE DO ,11 <- #1 + PLEASE DO ,12 <- #2 + PLEASE DO ,15 <- #5 + PLEASE DO ,16 <- #6 + DO ,15SUB#1 <- #240 + DO ,15SUB#4 <- #144 + DO ,15SUB#5 <- #0 + DO (3990) NEXT + + DO .11 <- #10 + DO .12 <- #4 + DO .13 <- #6 + PLEASE COME FROM (64) + DO (100) NEXT + + PLEASE NOTE THE GAME BEGINNING AND THE COMPUTER CHOOSING A CODE + + PLEASE COME FROM (40) + + DO .6 <- #1 + PLEASE COME FROM (12) + DO (1900) NEXT + DO .1 <- .1~#4095 + DO .2 <- .13 + DO (1039) NEXT + DO .1 <- .3~#61440 + DO (1020) NEXT + DO ,23SUB.6 <- .1 + DO .5 <- '?"'#65535~"'?.6$.12'~#21845"'~#1"$#1'~#3 + DO (13) NEXT + DO .1 <- .6 + DO (1020) NEXT +(12) DO .6 <- .1 +(13) DO (1001) NEXT + PLEASE FORGET #1 + + PLEASE NOTE THE OPENING OF THE GREAT LOOP + + DO .10 <- #1 + PLEASE COME FROM (42) + + PLEASE NOTE THE BOARD BEING DRAWN AND INPUT BEING GATHERED + + PLEASE COME FROM (62) + DO .4 <- #1 + DO (130) NEXT + DO ,16SUB#1 <- #158 + DO ,16SUB#2 <- #192 + DO ,16SUB#3 <- #136 + DO ,16SUB#4 <- #200 + DO ,16SUB#5 <- #70 + DO ,16SUB#6 <- #88 + PLEASE COME FROM (22) + PLEASE READ OUT ,16 + DO .1 <- .12 + DO .2 <- .13 + DO (3020) NEXT + DO .5 <- .4 + DO (23) NEXT + DO .5 <- '?"'#65535~"'?.3$#1'~'#0$#65535'"'~#1"$#1'~#3 + PLEASE COME FROM (28) +(26) DO (27) NEXT +(27) DO (1001) NEXT + PLEASE FORGET #1 + DO .1 <- ,1SUB#1 + DO (50) NEXT +(28) DO ,1SUB#1 <- #82 +(23) DO (1001) NEXT + PLEASE FORGET #1 + DO .5 <- '?"'#65535~"'?.3$.12'~#21845"'~#1"$#1'~#3 +(25) DO (24) NEXT + PLEASE COME FROM (26) + DO ,12SUB#1 <- #8 + DO ,12SUB#2 <- #172 +(22) PLEASE READ OUT ,12 +(24) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE READ OUT ,7 + DO .1 <- #1 + PLEASE COME FROM (20) + + DO ,22SUB.10.1 <- ,1SUB.1 + DO .5 <- '?"'#65535~"'?.1$.12'~#21845"'~#1"$#1'~#3 + DO (21) NEXT +(20) DO (1020) NEXT +(21) DO (1001) NEXT + PLEASE FORGET #1 + + PLEASE NOTE THE SCORING OF THE GUESS + + DO .6 <- #32768 + DO .7 <- #0 + DO .8 <- #0 + DO .2 <- #1 + PLEASE COME FROM (30) + DO .9 <- ,23SUB.2 + DO .5 <- '?"'#65535~"'?",22SUB.10.2"$.9'~#21845"'~#1"$#2'~#3 + DO (31) NEXT +(32) DO .7 <- 'V.7$.6'~'#0$#65535' +(31) DO (1001) NEXT + PLEASE FORGET #1 + DO .1 <- #1 + PLEASE COME FROM (33) + DO .5 <- '?"'#65535~"'?",22SUB.10.1"$.9'~#21845"'~#1"$#2'~#3 + DO (34) NEXT + PLEASE COME FROM (32) +(35) DO .8 <- 'V.8$.6'~'#0$#65535' +(34) DO (1001) NEXT + PLEASE FORGET #1 + DO .5 <- '?"'#65535~"'?.1$.12'~#21845"'~#1"$#1'~#3 + DO (36) NEXT +(33) DO (1020) NEXT +(36) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE COME FROM (35) + DO .6 <- .6~#65534 + DO .5 <- '?"'#65535~"'?.2$.12'~#21845"'~#1"$#1'~#3 + DO (37) NEXT + DO .1 <- .2 + DO (1020) NEXT +(30) DO .2 <- .1 +(37) DO (1001) NEXT + PLEASE FORGET #1 + DO ,21SUB.10#1 <- .7~.7 + DO ,21SUB.10#2 <- .8~.8 + DO .6 <- ',21SUB.10#1'~.20 + + PLEASE NOTE THE CLOSING OF THE GREAT LOOP + + DO .5 <- '?.6$#2'~#3 + DO (41) NEXT + DO .5 <- '?"'#65535~"'?.10$.11'~#21845"'~#1"$#1'~#3 + DO (41) NEXT + DO .1 <- .10 + DO (1020) NEXT +(42) DO .10 <- .1 +(41) DO (1001) NEXT + PLEASE FORGET #1 + DO .1 <- .10 + DO (1020) NEXT + DO .10 <- .1 + DO .4 <- #2 + DO (130) NEXT + + PLEASE NOTE THE GAME'S DENOUEMENT + + DO ,16SUB#1 <- #118 + DO ,16SUB#2 <- #24 + DO ,16SUB#3 <- #80 + DO ,16SUB#4 <- #232 + DO ,16SUB#5 <- #208 + DO ,16SUB#6 <- #182 + PLEASE READ OUT ,16 + DO .1 <- #1 + DO .2 <- #0 + DO (3020) NEXT + DO .5 <- '?"'#65535~"'?.3$#1'~'#0$#65535'"'~#1"$#2'~#3 + DO (43) NEXT + DO .1 <- ,1SUB#1 + DO (59) NEXT + DO (44) NEXT +(43) DO (1001) NEXT +(44) PLEASE FORGET #1 + PLEASE COME FROM (63) +(40) PLEASE READ OUT ,7 + + PLEASE NOTE THE HANDLING OF USER COMMANDS + +(50) DO .5 <- '?"'#65535~"'?.1$#82'~#21845"'~#1"$#1'~#3 + DO (52) NEXT + DO .5 <- '?"'#65535~"'?.1$#78'~#21845"'~#1"$#1'~#3 + DO (53) NEXT +(59) DO .5 <- '?"'#65535~"'?.1$#67'~#21845"'~#1"$#1'~#3 + DO (54) NEXT + DO .5 <- '?"'#65535~"'?.1$#81'~#21845"'~#1"$#1'~#3 + DO (55) NEXT + DO RESUME #1 +(52) DO (1001) NEXT + PLEASE FORGET #2 +(62) PLEASE READ OUT ,7 +(53) DO (1001) NEXT +(63) PLEASE FORGET #2 +(54) DO (1001) NEXT + DO ,11SUB#1 <- #88 + DO ,12SUB#1 <- #54 + DO ,12SUB#2 <- #190 + PLEASE READ OUT ,7 + ,12 + ,11 + PLEASE WRITE IN .1 + DO .5 <- '?"'.1~.1'~#1"$#1'~#3 + DO (51) NEXT + DO ,12SUB#1 <- #106 + DO ,12SUB#2 <- #62 + PLEASE READ OUT ,12 + ,11 + PLEASE WRITE IN .2 + DO .5 <- '?"'.2~.2'~#1"$#1'~#3 + DO (51) NEXT + DO ,12SUB#1 <- #146 + DO ,12SUB#2 <- #22 + PLEASE READ OUT ,12 + ,11 + PLEASE WRITE IN .3 + DO .5 <- '?"'.3~.3'~#1"$#1'~#3 + DO (51) NEXT + DO .11 <- .1~#15 + DO .12 <- .2~#15 + DO .13 <- .3~#15 + PLEASE FORGET #2 +(64) PLEASE READ OUT ,7 +(51) DO (1001) NEXT + PLEASE RESUME #3 +(55) DO (1001) NEXT + PLEASE FORGET #2 + PLEASE READ OUT ,7 + PLEASE GIVE UP + + PLEASE NOTE THE SUBROUTINE TO INITIALIZE GLOBAL VARIABLES + +(100) DO ,21 <- .11 BY #2 + DO ,22 <- .11 BY .12 + DO ,23 <- .12 + + DO .20 <- #1 + DO .1 <- #1 + PLEASE COME FROM (104) + DO .5 <- '?"'#65535~"'?.1$.12'~#21845"'~#1"$#1'~#3 + DO (105) NEXT + DO .20 <- !20$#0'~'#32767$#1' +(104) DO (1020) NEXT +(105) DO (1001) NEXT + PLEASE FORGET #1 + + DO ,1 <- .12 + DO ,2 <- .13 + DO ,10 <- .13 BY #2 + DO .1 <- #1 + PLEASE COME FROM (102) + DO .2 <- 'V.1$#48'~#21845 + DO ,2SUB.1 <- .2 + DO .2 <- !2~#15'$!2~#240' + DO .2 <- !2~#15'$!2~#240' + DO .2 <- !2~#15'$!2~#240' + DO .4 <- .1 + DO .1 <- #20 + DO (1010) NEXT + DO .1 <- .4 + DO ,10SUB.1#1 <- .3~#255 + DO ,10SUB.1#2 <- '?.3$#112'~#21845 + DO .5 <- '?"'#65535~"'?.1$.13'~#21845"'~#1"$#1'~#3 + DO (103) NEXT +(102) DO (1020) NEXT +(103) DO (1001) NEXT + PLEASE RESUME #2 + + PLEASE NOTE THE SUBROUTINE TO DISPLAY THE BOARD + +(130) PLEASE STASH .1 + .2 + .3 + .4 + .5 + DO .4 <- .20 + DO .5 <- '?".12~#1"$#1'~#3 + DO (131) NEXT + DO .4 <- !4$#0'~'#32767$#1' + DO (132) NEXT +(131) DO (1001) NEXT +(132) PLEASE FORGET #1 + DO .2 <- .4 + + PLEASE COME FROM (140) + PLEASE READ OUT ,6 + DO .1 <- #1 + PLEASE COME FROM (134) + DO .5 <- '?"'#65535~"'?.1$.10'~#21845"'~#1"$#1'~#3 + DO (133) NEXT + DO .3 <- .2~#65534 + PLEASE COME FROM (135) + DO .5 <- '?"',21SUB.1#1'~.3"$#1'~#3 + DO (139) NEXT + DO ,12SUB#1 <- #176 + DO ,12SUB#2 <- #80 + DO (137) NEXT +(139) DO (1001) NEXT + PLEASE FORGET #1 + DO .5 <- '?"',21SUB.1#2'~.3"$#1'~#3 + DO (138) NEXT + DO ,12SUB#1 <- #48 + DO ,12SUB#2 <- #208 + DO (137) NEXT +(138) DO (1001) NEXT + DO ,12SUB#1 <- #0 + DO ,12SUB#2 <- #0 +(137) PLEASE FORGET #1 + PLEASE READ OUT ,12 + DO .5 <- '?".3~.2"$#2'~#3 + DO (136) NEXT +(135) DO .3 <- .2 +(136) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE READ OUT ,5 +(134) DO (1020) NEXT +(133) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE READ OUT ,7 + DO .2 <- .2~#65532 + DO .5 <- '?".2~.2"$#1'~#3 +(140) DO (141) NEXT +(141) DO (1001) NEXT + PLEASE FORGET #1 + + PLEASE RETRIEVE .4 + DO ,16SUB#1 <- #0 + DO ,16SUB#2 <- #0 + DO ,16SUB#3 <- #240 + DO ,16SUB#6 <- #68 + DO .2 <- #0 + PLEASE COME FROM (150) + DO .1 <- .2 + DO (1020) NEXT + DO .2 <- .1 + PLEASE READ OUT ,6 + DO .1 <- #1 + DO .3 <- #0 + PLEASE COME FROM (142) + DO .5 <- '?"'#65535~"'?.1$.10'~#21845"'~#1"$#1'~#3 + DO (149) NEXT + DO .5 <- ,22SUB.1.2 + DO ,15SUB#2 <- ,10SUB.5#1 + DO ,15SUB#3 <- ,10SUB.5#2 + PLEASE READ OUT ,15 + DO .3 <- .1 +(142) DO (1020) NEXT +(149) DO (1001) NEXT + DO ,15SUB#2 <- #16 + DO ,15SUB#3 <- #112 +(148) DO .1 <- .3 + PLEASE COME FROM (144) + PLEASE READ OUT ,15 + DO (1020) NEXT + PLEASE COME FROM (148) + DO .5 <- '?"'#65535~"'?.1$.11'~#21845"'~#1"$#1'~#3 +(144) DO (143) NEXT +(143) DO (1001) NEXT + PLEASE FORGET #2 + DO .5 <- .4 + DO (145) NEXT + DO .5 <- ,23SUB.2 + DO ,16SUB#4 <- ,10SUB.5#1 + DO ,16SUB#5 <- ,10SUB.5#2 + DO (146) NEXT +(145) DO (1001) NEXT + DO ,16SUB#4 <- #24 + DO ,16SUB#5 <- #104 +(146) PLEASE FORGET #1 + PLEASE READ OUT ,16 + DO .5 <- '?"'#65535~"'?.2$.12'~#21845"'~#1"$#1'~#3 +(150) DO (147) NEXT +(147) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE READ OUT ,5 + PLEASE RETRIEVE .1 + .2 + .3 + .5 + PLEASE RESUME #1 + + PLEASE USE THE AUTHORIZED CHANNELS + +(3000) DO STASH .2 + .3 + DO .1 <- ,3000SUB#1 + PLEASE WRITE IN ,3000 + DO .2 <- ,3000SUB#1 + DO (1000) NEXT + DO .1 <- .3~#255 + DO ,3000SUB#1 <- .1 + DO RETRIEVE .2 + .3 + PLEASE RESUME #1 + +(3020) PLEASE STASH .1 + .5 + .6 + .7 + DO (1020) NEXT + DO .3 <- #0 + DO .4 <- #6 + DO .6 <- .1 + DO (3022) NEXT +(3021) DO (1001) NEXT +(3022) PLEASE FORGET #1 + DO (3000) NEXT + DO .5 <- '?"?.1~#256"$#2'~#3 + DO (3023) NEXT + DO .5 <- '?"'#65535~"'?.1$#10'~#21845"'~#1"$#1'~#3 + DO (3023) NEXT + DO .7 <- .1 + DO .1 <- .3 + PLEASE DO (1020) NEXT + DO .3 <- .1 + DO .5 <- .4~#3 + DO (3021) NEXT + DO .5 <- '?"'#65535~"'?.3$.6'~'#0$#65535'"'~#1"$#1'~#3 + DO .4 <- !4$.5'~#37 + DO (3021) NEXT +(3027) DO .1 <- #0 + PLEASE COME FROM (3024) + PLEASE DO (1020) NEXT + DO .5 <- '?"'#65535~"'?.7$",2SUB.1"'~#21845"'~#1"$#1'~#3 + DO (3025) NEXT + PLEASE COME FROM (3027) + DO .5 <- '?"'#65535~"'?.1$.2'~'#0$#65535'"'~#1"$#1'~#3 +(3024) DO (3026) NEXT +(3026) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE DO ,1SUB.3 <- .7 + DO .4 <- .4~#3 + DO (3022) NEXT +(3025) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE DO ,1SUB.3 <- .1 + DO (3022) NEXT +(3023) DO (1001) NEXT + PLEASE RETRIEVE .1 + .5 + .6 + .7 + DO .4 <- '?#2$.&4'~#6 + PLEASE RESUME #2 + +(3990) DO ,3000 <- #1 + DO ,3000SUB#1 <- #0 + DO ,3001 <- #1 + DO ,3001SUB#1 <- #0 + PLEASE RESUME #1 diff --git a/pit/lib/floatlib.doc b/pit/lib/floatlib.doc new file mode 100644 index 0000000..150097b --- /dev/null +++ b/pit/lib/floatlib.doc @@ -0,0 +1,249 @@ +* Summary of routines in floatlib.i: + + (5000) :3 <- :1 plus :2 + (5010) :3 <- :1 minus :2 + (5020) :2 <- the integer part of :1 + :3 <- the fractional part of :1 + (5030) :3 <- :1 times :2 + (5040) :3 <- :1 divided by :2 + (5050) :3 <- :1 modulo :2 + + (5060) :2 <- :1 cast from a two's-complement integer into a + floating-point number + (5070) :2 <- :1 cast from a floating-point number into the nearest + two's-complement integer + (5080) :2 <- :1 cast from a floating-point number into a decimal + representation in scientific notation + (5090) :2 <- :1 cast from a decimal representation in scientific + notation into a floating-point number + + (5100) :2 <- the square root of :1 + (5110) :2 <- the natural logarithm of :1 + (5120) :2 <- e to the power of :1 (the exponential function) + (5130) :3 <- :1 to the power of :2 + + (5200) :2 <- sin :1 + (5210) :2 <- cos :1 + (5220) :2 <- tan :1 + + (5400) :1 <- uniform random number between zero and one exclusive + (5410) :2 <- :1 times phi + (5419) :2 <- :1 divided by phi + +Note: All of the above routines except (5020), (5060), (5080), (5200), +(5210), and (5400) also modify .5 as follows: .5 will contain #3 if +the result overflowed or if the arguments were out of domain, #2 if +the result underflowed, #1 otherwise. (See below.) + +* Description of floatlib.i: + +The INTERCAL floating-point library uses the IEEE format for 32-bit +floating-point numbers, which uses bit 31 as a sign bit (1 being +negative), bits 30 through 23 hold the exponent with a bias of 127, +and bits 22 through 0 contain the fractional part of the mantissa with +an implied leading 1. In mathematical notation: + + N = (1.0 + fraction) * 2^(exponent - 127) * -1^sign + +Thus the range of floating-point magnitudes is, roughly, from +5.877472*10^-39 up to 6.805647*10^38, positive and negative. Zero is +specially defined as all bits 0. (Actually, to be precise, zero is +defined as bits 30 through 0 as being 0. Bit 31 can be 1 to represent +negative zero, which the library generally treats as equivalent to +zero, though don't hold me to that.) + +Note that, contrary to the IEEE standard, exponents 0 and 255 are not +given special treatment (besides the representation for zero). Thus +there is no representation for infinity or not-a-numbers, and there is +no gradual underflow capability. Conformance with widely-accepted +standards was not considered to be a priority for an INTERCAL library. +(The fact that the general format conforms to IEEE at all is due to +sheer pragmatism.) + +Here, for easy reference, are some common values as they would be +directly represented within an INTERCAL program: + + Zero: #0 + One: #30720$#28672 + Two: #0$#32768 + One million: #9280$#40480 + One-half: #28672$#28672 + Square root of two: #31757$#30509 + e: #1760$#33742 + Pi: #571$#35133 + +However, a more human-accessible representation of floating-point +numbers is made possible by the routines (5080) and (5090). For this +representation, scientific notation is used with six digits of +precision after the decimal point. The seven digits of the mantissa +are suffixed with the two digits of the exponent. If the number is +negative, a one is prefixed (in the billions' place), so there can be +ten decimal digits in all. Finally, if the exponent is negative, fifty +is added. As is the usually the case with scientific notation, the +digit to the left of the decimal point must be nonzero except for the +case of zero itself. + +The above may sound convoluted, but it is not nearly as confusing as +it perhaps should be. As an example, if you wished to enter the value +of the speed of light measured in centimeters per seconds squared, you +would type TWO NINE NINE SEVEN NINE TWO FIVE ONE OH. The INTERCAL +program would then call (5080) to transform this into the +floating-point number 2.997925e+10. The same value printed out with + _____ +the help of (5090) would appear as ccxcixDCCXCMMDX. Similarly, the +value -1.602189e-19 (the charge of an electron measured in Coulombs) +would be represented respectively as ONE ONE SIX ZERO TWO ONE EIGHT + _______ +NINE SIX NINE and mclxCCXVIIICMLXIX. Note that the negative sign on +the exponent always translates to an L between the fraction and the +exponent when output. + +The 16-bit variable .5 is used by the floating-point library as an +error indicator. Upon return from most of the functions, .5 will +normally be set to #1 if the return value is valid. If .5 is set to +#2, this indicates that the result of the function underflowed (that +is, the magnitude of the result is less than 2^-127). If .5 is set to +#3, this indicates either that the result overflowed (magnitude +greater than 2^128), or that the arguments to the function were +illegal. The latter can occur for the following situations: division +by zero (either via division or modulus), negative root (either via +square root or a fractional power), and non-positive logarithm. Also, +(5070) will set .5 to #3 if the magnitude of the argument is greater +than 2^31, and (5080) will do likewise if given a bad number (e.g., if +it is greater than two billion). + +It may be worth nothing that there are some cases in which an under- +or overflow can be recovered from with tolerable grace. The sign and +fraction bits of such a value will usually still be correct, and the +exponent bits will just be the lower eight bits of the true exponent: +that is, the true exponent plus or minus 256 as appropriate. If such a +value is passed to another function as is, and the return value from +that over- or underflows in the opposite direction, it is likely that +the final result can be trusted. Of course, this depends entirely on +the nature of the operations involved, and this paragraph should not +be taken as advice to pursue such approaches in general, just as this +document should not be taken as advice to make use of this library at +all. Note also that in the case of (5110), the exponential function, +and (5130), the power function, it is quite easy to request a +massively under- and/or overflowed result. In these cases the +functions in question exit early, and attempting to salvage something +from such results, with the possible exception of the sign bit, is +pretty much guaranteed to be fruitless. + +(5020) is the integral partition function (referred to as modf in the +C library). Both return values are floating-point numbers, and both +have the same sign as the argument, such that :2 + :3 = :1 while +keeping the magnitude of :3 less than 1. + +(5060) and (5070) are the "type-casting" functions. They translate +values to and from 32-bit two's-complement integers. (5070) truncates +any fractional amounts from its argument, and will signal an error if +the magnitude of the value requires more than 32 bits. + +The trigonometric functions (5200), (5210), and (5220) will return +erroneous results when given very large arguments. At magnitudes +around 8 million or so, the result is occasionally off by one bit. +The errors get progressively worse, so that with magnitudes in the +neighborhood of the quintillions and higher, the number is wholly +inaccurate. However, at magnitudes around 8 million, there is already +a difference of over 20pi between consecutive floating-point numbers, +so it is hard to conceive of a purpose for which improved accuracy +would be useful. + +In the descriptions for (5410) and (5419), phi refers to the golden +ratio. + +* Internal routines in floatlib.i: + +A floating-point library involves a fair amount of mathematical +functionality to begin with, something that INTERCAL is not generally +mistaken for having. The floating-point library therefore has a number +of internal functions to provide it with some 64-bit arithmetic, among +other things. While these routines were designed specifically for +internal use, and in many cases one would be hard-pressed to find +other uses for them in their current form, it was felt that they were +nonetheless worth documenting. Besides providing a guide for anyone so +foolish as to examine the actual code, it provides a sort of "itemized +bill" that helps to justify the inordinate size of the library. + +In the following list, the notation :1:2 simply indicates that two +32-bit variables, in this example :1 and :2, are being used to hold a +single 64-bit integer value. The notation :1:2.1, on the other hand, +indicates a kind of double-precision floating-point value, a format +that the library uses frequently when storing intermediate values. The +two 32-bit variables hold the fraction bits, with no implied bits, and +ideally with the highest 1 bit at bit 55. The 16-bit variable holds +the exponent, but with a bias of 639 instead of 127. This is done so +that underflows do not affect the sign, which is also stored in the +16-bit variable in bit 10. These intermediate values are rounded (to +even), truncated, and stored in a single 32-bit variable by the +floating-point normalization function, (5600). + +Finally, note that the numbers in the tables accessed by routines +(5690) through (5693) are generally tailored for the function that +applies them, and all of them use slightly different representations +for the values they encode. + +Here are brief descriptions of the internal routines: + + (5500) :1:2 <- :1:2 plus :3:4 + .5 <- #0 if no overflow, #1 otherwise + (5510) :1 <- :1 plus :6, where :6 has at most one 1 bit + :6 <- #0 on overflow, nonzero otherwise + (5519) :1 <- :1 minus :6, where :6 has at most one 1 bit + :6 <- #0 on underflow, nonzero otherwise + (5520) .1 <- .1 minus #1 + (5530) :1:2:3:4 <- :1:2 times :3:4 + (5540) :1 <- :1:2 divided by :3:4, with :1:2 aligned on bit 63, :3:4 + aligned on bit 62, and the result aligned on bit 31 + .1 <- the exponent of the quotient plus #126 + .5 <- #1 if the result should be rounded up, #0 otherwise + (5550) :1:2.1 <- :1:2.1 modulo :3:4.2 + (5560) :1:2 <- two's complement of :1:2 + (5570) :1:2 <- :1:2 left-shifted logically so that bit 63 is 1 + .1 <- .1 minus the no. of bits shifted out + (5580) :3:4 <- :3:4 shifted right arithmetically .3 bits + (5590) :1:2 <- :1:2 shifted so that bit 55 is the highest 1 bit + .1 <- .1 plus or minus the no. of bits shifted + .5 <- the bits right-shifted out of :1:2, if any + (5600) :1 <- the normalization of :1:2.1 + (5610) :1:2.1 <- the natural logarithm of :1:2.1 + (5620) :1:2.1 <- e to the power of :1:2.1 + (5640) :1:2.1 <- :1:2.1 to the power of the two's-complement integer + in :3 + (5650) :1:2.1 <- :1 to the power of :2 + .5 <- #1 if the power is not real, #2 otherwise + (5670) :1:2 <- an angle between -pi/2 and pi/2 that has the same + value for sine as :1, and stored in two's-complement, + fixed-point form, with the one's position at bit 62 + .1 <- #1024 if the cosine of :1:2 will have the opposite sign + as the cosine of :1, #2048 otherwise + (5680) :1:2 <- the sine of :1:2 in two's-complement, fixed-point + :3:4 <- the cosine of :1:2 + (5690) ;1 <- a table of 32 significant bits of the numbers 10^i, + where i ranges from 1 to 39 + ,1 <- a table of exponents for the above powers of ten + (5691) ;1 <- a table of bit patterns representing ln(1 + 1/(2^i - 1)), + where i ranges from -1 to -26 + (5692) ;1 <- a table of bit patterns representing -ln(1 + 2^i), where + i ranges from -1 to -32 + (5693) ;1 <- a table of bit patterns representing arctan(2^i), where + i ranges from 0 to -30 + +* Bibliography: + +Knuth, Donald E. "The Art of Computer Programming: Vol. 2 +(Seminumerical Algorithms)", 2nd edition. Addison-Wesley, 1981. + This book provided the essential background as well as algorithms + for the basic arithmetic operations. Mention should also be made + of Vol. 1, which provided an algorithm for the natural logarithm + as a side note. + +Koren, Israel. "Computer Arithmetic Algorithms". Prentice-Hall, 1993. + In addition to information on the IEEE standard, this book + provided the algorithms used for the exponential and trigonometric + functions. + +Plauger, P. J. "The Standard C Library". Prentice-Hall, 1992. + This book provided assistance in designing the modulus and power + functions, as well as other miscellaneous contributions. diff --git a/pit/lib/floatlib.i b/pit/lib/floatlib.i new file mode 100644 index 0000000..7eac197 --- /dev/null +++ b/pit/lib/floatlib.i @@ -0,0 +1,1993 @@ + PLEASE USE A DESIGNATED ENTRY POINT + +(5000) PLEASE ABSTAIN FROM (5005) +(5010) PLEASE STASH .1 + .2 + .3 + :1 + :2 + :4 + :6 + DO :4 <- :1 +(5005) PLEASE DO :2 <- '"?':2~"#65535$#0"'$#32768"~"#0$#65535"'$ + ':2~"#0$#65535"' + DO :6 <- '"?':1~"#32767$#0"'$':2~"#32767$#0"'"~"#0$#32767"'$ + '"?':1~"#0$#65535"'$':2~"#0$#65535"'"~"#0$#65535"' + DO .5 <- '?"':2~:6'~'"?:6~:6"~"#32767$#65535"'"$#1'~#3 + DO (5001) NEXT + DO :1 <- :2 + DO :2 <- :4 + DO :4 <- :1 + DO (5002) NEXT +(5001) DO (1001) NEXT +(5002) PLEASE FORGET #1 + DO .5 <- '?"':2~":2~'#32767$#65535'"'~#1"$#1'~#3 + DO (5006) NEXT + DO .5 <- '?"'?":1~'#32768$#0'"$":2~'#32768$#0'"'~#1"$#1'~#3 + PLEASE DO .1 <- '"'":1~'#63488$#61440'"$#256'~'#511$#256'"$ + #0'~'#1023$#256' + DO :1 <- '"':1~"#2047$#0"'$#2048"~"#2047$#2048"'$':1~"#0$#4095"' + DO .2 <- :2~'#30720$#61440' + DO :3 <- '"':2~"#2047$#0"'$#2048"~"#2047$#2048"'$':2~"#0$#4095"' + DO (5003) NEXT + DO :2 <- :1 + DO :1 <- '"?':3~"#65535$#0"'$#65535"~"#0$#65535"'$'"?':3~"#0$ + #65535"'$#65535"~"#0$#65535"' + DO :6 <- #1 + DO (5510) NEXT + DO :3 <- :1 + DO :1 <- :2 + DO (5004) NEXT +(5003) DO (1001) NEXT +(5004) PLEASE FORGET #1 + DO .5 <- .1 + DO .1 <- .1~#255 + DO (1010) NEXT + DO .1 <- .5 + PLEASE DO .5 <- .3~#65504 + DO .5 <- '?"'V"!5~.5'~#1"$"'V.3~#6'~'".3~#16"~".3~#8"'"'~#1"$ + #2'~#3 + DO (5006) NEXT + DO :4 <- #0 + DO (5580) NEXT + DO :2 <- :3 + DO :6 <- :4 + DO (1509) NEXT + DO :1 <- :3 + DO :2 <- :6 + PLEASE DO (5600) NEXT + DO :3 <- :1 + DO (5007) NEXT +(5006) DO (1001) NEXT + DO :3 <- :4 +(5007) PLEASE RETRIEVE .1 + .2 + .3 + :1 + :2 + :4 + :6 + PLEASE REINSTATE (5005) + PLEASE RESUME #2 + +(5020) PLEASE STASH .1 + .2 + .3 + .5 + :1 + DO .1 <- #150 + DO .2 <- :1~'#30720$#61440' + DO (1010) NEXT + DO .5 <- '?"!3~.3'~#1"$#1'~#3 + DO (5022) NEXT + DO .5 <- '?".3~#32768"$#2'~#3 + DO (5022) NEXT + DO :2 <- #0 + DO :3 <- :1 + PLEASE DO .5 <- '?"'V"'V"V.V3"'~#32"$".&3~#8"'~#1"$#2'~#3 + DO (5021) NEXT + DO .1 <- .3 + DO :2 <- #1 + DO (5023) NEXT +(5024) DO (1001) NEXT +(5023) PLEASE FORGET #1 + DO :2 <- :V2 + DO (5520) NEXT + DO .5 <- '?"!1~.1'~#1"$#2'~#3 + DO (5024) NEXT + PLEASE DO :2 <- :2~:&2 + DO :2 <- '"&':1~"#65535$#0"'$':2~"#65535$#0"'"~"#0$#65535"'$ + '"&':1~"#0$#65535"'$':2~"#0$#65535"'"~"#0$#65535"' + DO .5 <- '?"':2~:2'~#1"$#1'~#3 + DO (5022) NEXT + DO :3 <- '"?':1~"#65535$#0"'$':2~"#65535$#0"'"~"#0$#65535"'$ + '"?':1~"#0$#65535"'$':2~"#0$#65535"'"~"#0$#65535"' + PLEASE DO .1 <- '":1~'#65535$#0'"$"'#512$.2'~'#768$ + #255'"'~'#32768$#1023' + DO :1 <- :2 + DO :2 <- #0 + DO (5590) NEXT + DO :2 <- :3 + PLEASE DO :3 <- '"'"'"'".1$':1~#32768'"~"#1109$#1"'$ + ':1~#128'"~#2735'$':1~"#546$#0"'"~"#43679"'$':1~"#1365$ + #0"'"~"#1023$#63"'$'"'"'".1$#0"~#34959'$':1~"#0$ + #1170"'"~#11007'$':1~"#0$#2925"'"~"#2005$#255"' + DO (5025) NEXT +(5022) DO (1001) NEXT + PLEASE FORGET #1 + DO :2 <- :1 + DO :3 <- #0 + DO (5025) NEXT +(5021) DO (1001) NEXT +(5025) PLEASE RETRIEVE .1 + .2 + .3 + .5 + :1 + PLEASE RESUME #2 + +(5030) DO :3 <- #0 + DO .5 <- '?"'":1~':1~"#32767$#65535"'"~":2~':2~"#32767$ + #65535"'"'~#1"$#1'~#3 + DO (5041) NEXT + PLEASE STASH .1 + .2 + .3 + :1 + :2 + :4 + :5 + PLEASE DO .1 <- '"'":1~'#63488$#61440'"$#256'~'#511$#256'"$ + #0'~'#1023$#256' + DO :4 <- '"':1~"#2047$#0"'$#2048"~"#2047$#2048"'$':1~"#0$#4095"' + PLEASE DO .2 <- '"'":2~'#63488$#61440'"$#0'~'#511$#256'"$ + #0'~'#1023$#256' + DO :5 <- '"':2~"#2047$#0"'$#2048"~"#2047$#2048"'$':2~"#0$#4095"' + DO (1000) NEXT + DO .1 <- .3~#2047 + DO .2 <- #126 + DO (1010) NEXT + PLEASE DO .1 <- '":4~'#3855$#3855'"$#0'~'#65280$#255' + DO .2 <- '":5~'#3855$#3855'"$#0'~'#65280$#255' + DO (1530) NEXT + DO :3 <- :1 + DO .1 <- .1~#65280 + DO .2 <- :5~#65535 + DO (1530) NEXT + DO :2 <- :1 + DO .1 <- :4~#65535 + DO (1530) NEXT + DO .2 <- :5~'#3840$#3840' + DO :4 <- '"':3~"#65535$#0"'$':1~"#65280$#0"'"~"#65280$#255"'$ + '"':3~"#0$#65535"'$':1~"#0$#65280"'"~"#65280$#255"' + DO :5 <- :1~#65535 + DO (1530) NEXT + DO (1500) NEXT + DO :1 <- :3 + DO :2 <- :4 + DO (1500) NEXT + DO :1 <- :3~'#65520$#65520' + PLEASE DO :2 <- '"'&"V:3~#128"'$'":5~:5"~#1'"~"#32768$#32767"'$ + '"'&"V:3~#64"'$':3~#63'"~"#32768$#32767"' + DO .1 <- .3 + PLEASE DO (5600) NEXT + DO :3 <- :1 + PLEASE RETRIEVE .1 + .2 + .3 + :1 + :2 + :4 + :5 + PLEASE RESUME #1 + +(5040) DO :3 <- #0 + PLEASE DO .5 <- '?#1$"':2~":2~'#32767$#65535'"'~#1"'~#3 + DO (5041) NEXT + DO .5 <- '?"':1~":1~'#32767$#65535'"'~#1"$#1'~#3 + DO (5041) NEXT + PLEASE STASH .1 + .2 + .3 + :1 + :2 + :4 + PLEASE DO .1 <- '"'":1~'#63488$#61440'"$#256'~'#511$#256'"$ + #0'~'#1023$#256' + DO .2 <- '"'":2~'#63488$#61440'"$#0'~'#511$#256'"$#0'~'#1023$ + #256' + DO (1010) NEXT + DO :1 <- '"'"':1~"#2047$#1"'$#4096"~"#4094$#4099"'$#0"~"#16383$ + #3"'$'"'"'"':1~"#0$#4095"'$#0"~"#4095$#1"'$#0"~"#8191$ + #1"'$#0"~"#16383$#3"' + PLEASE DO :3 <- '"'"':2~"#0$#4095"'$#0"~"#4095$#1"'$#0"~"#8191$ + #3"'$'"'"':2~"#2047$#1"'$#32768"~"#4094$#32771"'$ + #0"~"#16383$#3"' + DO :2 <- #0 + DO :4 <- #0 + DO (5540) NEXT + DO .2 <- .3 + DO (1000) NEXT + DO .1 <- .3 + DO :2 <- '&"V:1~#64"'$'"':1~#63'$.5"~#2735' + DO :1 <- :1~'#65528$#65520' + PLEASE DO (5600) NEXT + DO :3 <- :1 + PLEASE RETRIEVE .1 + .2 + .3 + :1 + :2 + :4 + PLEASE RESUME #1 +(5041) DO (1001) NEXT + PLEASE RESUME #2 + +(5050) DO :3 <- #0 + PLEASE DO .5 <- '?#1$"':2~":2~'#32767$#65535'"'~#1"'~#3 + DO (5051) NEXT + DO .5 <- '?"':1~":1~'#32767$#65535'"'~#1"$#1'~#3 + DO (5051) NEXT + PLEASE STASH .1 + .2 + .3 + :1 + :2 + :4 + PLEASE DO .1 <- '"'":1~'#63488$#61440'"$#256'~'#511$#256'"$ + #0'~'#1023$#256' + DO :1 <- '"':1~"#2047$#0"'$#2048"~"#2047$#2048"'$':1~"#0$#4095"' + DO .2 <- :2~'#30720$#61440' + DO :2 <- '"':2~"#2047$#0"'$#2048"~"#2047$#2048"'$':2~"#0$#4095"' + DO (5052) NEXT +(5053) DO (1001) NEXT +(5052) PLEASE FORGET #1 + DO .5 <- '?.1$.2'~'#0$#255' + DO .5 <- '?"!2~.5'~'"?.5~.5"~#255'"$#2'~#3 + DO (5054) NEXT + DO (1510) NEXT + DO .5 <- '?":3~'#32768$#0'"$#2'~#3 + DO (5056) NEXT + DO :1 <- :3 + DO (5055) NEXT +(5056) DO (1001) NEXT +(5055) PLEASE FORGET #1 + DO .5 <- '?":1~'#32768$#0'"$#1'~#3 + DO (5057) NEXT + DO :2 <- :2~'#65535$#65534' + DO .5 <- '?"':2~:2'~#1"$#1'~#3 + DO (5054) NEXT + DO .3 <- .1 + DO .1 <- .2 + DO (1020) NEXT + DO .2 <- .1 + DO .1 <- .3 + DO (5052) NEXT +(5057) DO (1001) NEXT + PLEASE FORGET #1 + DO :1 <- ':1~"#0$#65535"'$'"':1~"#32767$#0"'$#0"~"#32767$#1"' + DO (5520) NEXT + DO (5052) NEXT +(5054) DO (1001) NEXT + DO :2 <- #0 + PLEASE DO (5600) NEXT + DO :3 <- :1 + PLEASE RETRIEVE .1 + .2 + .3 + :1 + :2 + :4 + PLEASE RESUME #2 +(5051) DO (1001) NEXT + PLEASE RESUME #2 + +(5060) PLEASE STASH .1 + .5 + :1 + DO :2 <- #0 + DO .5 <- '?":1~'#32768$#0'"$#1'~#3 + DO (5061) NEXT + DO .1 <- #1686 + DO (5560) NEXT + DO (5062) NEXT +(5061) DO (1001) NEXT + DO .1 <- #662 +(5062) PLEASE DO (5600) NEXT + DO :2 <- :1 + PLEASE RETRIEVE .1 + .5 + :1 + PLEASE RESUME #2 + +(5070) PLEASE STASH .1 + .2 + .3 + :1 + :3 + :4 + :6 + DO .1 <- #157 + DO .2 <- :1~'#30720$#61440' + DO (1010) NEXT + DO .5 <- '?".3~#32768"$#2'~#3 + DO (5071) NEXT + PLEASE DO :3 <- '"'"':1~"#0$#4095"'$#0"~"#4095$#1"'$#0"~"#8191$ + #3"'$'"'"':1~"#2047$#1"'$#32768"~"#4094$#32771"'$ + #0"~"#16383$#3"' + DO (5580) NEXT + DO .5 <- '?":1~'#32768$#0'"$#1'~#3 + DO (5072) NEXT + DO :1 <- '"?':3~"#65535$#0"'$#65535"~"#0$#65535"'$'"?':3~"#0$ + #65535"'$#65535"~"#0$#65535"' + DO :6 <- #1 + DO (5510) NEXT + DO :2 <- :1 + DO (5073) NEXT +(5071) DO (1001) NEXT + PLEASE FORGET #1 + DO :6 <- :1~'#32768$#0' + DO :1 <- #32767$#65535 + DO (5510) NEXT + DO :2 <- :1 + PLEASE DO .5 <- #3 + DO (5073) NEXT +(5072) DO (1001) NEXT + DO :2 <- :3 +(5073) PLEASE RETRIEVE .1 + .2 + .3 + :1 + :3 + :4 + :6 + PLEASE RESUME #2 + +(5080) PLEASE STASH .1 + .2 + .3 + .4 + .5 + .6 + .7 + .8 + :1 + :3 + + :4 + :5 + :6 + ,1 + ;1 + DO .5 <- '?"':1~":1~'#32767$#65535'"'~#1"$#1'~#3 + DO (5088) NEXT + PLEASE DO (5690) NEXT + DO :5 <- :1~'#32767$#65535' + DO .5 <- '?":1~'#32768$#0'"$#1'~#3 + DO (5081) NEXT + PLEASE DO .6 <- #65535 + DO (5082) NEXT +(5081) DO (1001) NEXT + PLEASE DO .6 <- #1 +(5082) PLEASE FORGET #1 + DO .1 <- :5~'#30720$#61440' + DO .2 <- #65409 + DO (1009) NEXT + DO .5 <- '?".3~#32768"$#1'~#3 + DO (5083) NEXT + PLEASE DO .7 <- #65535 + DO .1 <- '?.3$#65535'~'#0$#65535' + DO (1020) NEXT + DO (5084) NEXT +(5083) DO (1001) NEXT + PLEASE DO .7 <- #1 + DO .1 <- .3 +(5084) PLEASE FORGET #1 + PLEASE DO .2 <- #39457 + DO (1530) NEXT + DO .1 <- :1~'#65280$#65024' + DO .2 <- .7~#32768 + DO (1000) NEXT + DO .8 <- .3 + DO (5019) NEXT +(5087) DO (1001) NEXT + DO .1 <- .8 + DO .2 <- .7 + DO (1009) NEXT + DO .8 <- .3 +(5019) PLEASE FORGET #1 + DO :1 <- '"'"':5~"#2047$#1"'$#4096"~"#4094$#4099"'$#0"~"#16383$ + #3"'$'"'"'"':5~"#0$#4095"'$#0"~"#4095$#1"'$#0"~"#8191$ + #1"'$#0"~"#16383$#3"' + DO :2 <- #0 + DO .1 <- :5~'#30720$#61440' + DO .5 <- '?"!8~.8'~#1"$#1'~#3 + DO (5018) NEXT + DO :3 <- ';1SUB.8'~'#65535$#65534' + DO :4 <- '&"V';1SUB.8'~#1"'$#0 + DO .2 <- ,1SUB.8 + DO .5 <- '?".7~#32768"$#1'~#3 + DO (5085) NEXT + DO (1020) NEXT + DO (1009) NEXT + PLEASE DO (5530) NEXT + DO (5086) NEXT +(5085) DO (1001) NEXT + PLEASE FORGET #1 + DO (1010) NEXT + PLEASE DO (5540) NEXT + DO :2 <- '&"V:1~#1"' + DO :1 <- :1~'#65535$#65534' + DO .2 <- .3 + DO (1009) NEXT + DO .1 <- .3 + DO .2 <- #65410 + DO (1009) NEXT + DO (5086) NEXT +(5018) DO (1001) NEXT + DO :2 <- '&"V:1~#1"' + DO :1 <- :1~'#65535$#65534' + DO .3 <- .1 +(5086) PLEASE FORGET #1 + DO :3 <- :1 + DO :4 <- :2 + DO .1 <- #157 + DO .2 <- .3 + DO (1010) NEXT + DO (5580) NEXT + PLEASE DO .5 <- '?"'V":3~#16"$"&':3~#8'$':V3~#2'"'~#1"$#2'~#3 + DO (5087) NEXT + DO :1 <- :3 + DO :2 <- :4 + DO :3 <- #0 + PLEASE DO :4 <- #784$#904 + DO (5530) NEXT + DO :1 <- :3 + DO :6 <- :4~'#32768$#0' + DO (5510) NEXT + DO :2 <- #100 + DO (1540) NEXT + DO .1 <- .8 + PLEASE DO .2 <- #50~.7 + DO (1000) NEXT + DO :1 <- :3 + DO :2 <- .3 + DO (1500) NEXT + DO :1 <- :3 + PLEASE DO :2 <- '#31664$#21632'~!6$.6' + DO (1500) NEXT + DO :2 <- :3 + DO (5089) NEXT +(5088) DO (1001) NEXT + DO :2 <- #0 +(5089) PLEASE FORGET #1 + PLEASE RETRIEVE .1 + .2 + .3 + .4 + .5 + .6 + .7 + .8 + :1 + + :3 + :4 + :5 + :6 + ,1 + ;1 + PLEASE RESUME #1 + +(5090) PLEASE DO :2 <- '"?':1~"#65535$#0"'$#21660"~"#0$#65535"'$ + '"?':1~"#0$#65535"'$#63326"~"#0$#65535"' + PLEASE DO .5 <- #1$"#3~'"'":1~:2"~"'?:2~:2'~'#32767$ + #65535'"'~#1"$"'":1~'#32768$#0'"~"':2~:2'~'#32768$ + #0'"'~#1"'" + DO :2 <- #0 + DO (5091) NEXT + PLEASE STASH .1 + .2 + .3 + .4 + .6 + .7 + .8 + :1 + :3 + :4 + + :5 + :6 + :7 + :8 + :9 + ,1 + ;1 + PLEASE DO (5690) NEXT + PLEASE DO :2 <- #33872$#43872 + DO (1509) NEXT + DO .5 <- :4 + DO (5091) NEXT + DO :1 <- :3 + DO .7 <- #65535 + DO (5092) NEXT +(5091) DO (1001) NEXT + DO .7 <- #1 +(5092) PLEASE FORGET #1 + DO :6 <- #0 + DO :7 <- #0 + PLEASE DO :5 <- #38368$#10099 + PLEASE DO :4 <- #63085$#14998 + PLEASE DO :8 <- #20480$#16384 + DO :9 <- :1 + DO (5093) NEXT +(5094) DO (1001) NEXT +(5093) PLEASE FORGET #1 + DO :1 <- :9 + DO :2 <- :8 + DO (1510) NEXT + DO .5 <- '?":3~'#32768$#0'"$#2'~#3 + DO (5095) NEXT + DO :9 <- :3 + DO :1 <- :6 + DO :2 <- :7 + DO :3 <- :5 + DO (5500) NEXT + DO :6 <- :1 + DO :7 <- :2 + DO (5096) NEXT +(5095) DO (1001) NEXT +(5096) PLEASE FORGET #1 + DO :4 <- '"'V:5~#1'$':4~"#0$#65534"'"~"#32768$#32767"'$ + ':4~"#65535$#0"' + DO :5 <- :5~'#65535$#65534' + DO :8 <- :8~'#65535$#65534' + DO .5 <- '?":8~#2"$#1'~#3 + DO (5094) NEXT + DO :1 <- :6 + DO :2 <- :7 + DO .1 <- :9 + PLEASE DO .5 <- '?"'V".1~#64"$".&1~#16"'~#1"$#1'~#3 + DO (5097) NEXT + DO .8 <- #65535 + DO .2 <- #65486 + DO (1009) NEXT + DO .1 <- .3 + DO (5098) NEXT +(5097) DO (1001) NEXT + DO .8 <- #1 +(5098) PLEASE FORGET #1 + DO .5 <- '?.1$#38'~'#0$#65535' + DO .5 <- '?"'.1~.5'~'"?.5~.5"~#32767'"$#2'~#3 + DO (5015) NEXT + DO .5 <- '?"!1~.1'~#1"$#1'~#3 + DO (5014) NEXT + DO .2 <- ,1SUB.1 + DO .5 <- '?".8~#32768"$#1'~#3 + DO (5017) NEXT + DO :3 <- ';1SUB.1'~'#65535$#65534' + DO :4 <- '&"V';1SUB.1'~#1"'$#0 + DO (5540) NEXT + PLEASE DO :2 <- .V5$#0 + DO (1010) NEXT + DO .1 <- .3 + DO .2 <- #508 + DO (1000) NEXT + DO (5016) NEXT +(5017) DO (1001) NEXT + PLEASE FORGET #1 + DO :3 <- ;1SUB.1 + DO :4 <- #0 + DO (5530) NEXT + DO .1 <- #635 + DO (1000) NEXT + DO (5016) NEXT +(5014) DO (1001) NEXT + DO .3 <- #634 +(5016) PLEASE FORGET #1 + DO .1 <- !7$.3'~'#1024$#1023' + PLEASE DO (5600) NEXT + DO :2 <- :1 + DO (5099) NEXT +(5015) DO (1001) NEXT + PLEASE FORGET #1 + DO :2 <- #0 + PLEASE DO .5 <- #1$'"?!8~#32768'$#1"~#1' + DO (5099) NEXT +(5099) PLEASE RETRIEVE .1 + .2 + .3 + .4 + .6 + .7 + .8 + :1 + :3 + + :4 + :5 + :6 + :7 + :8 + :9 + ,1 + ;1 + PLEASE RESUME #2 + +(5100) DO :2 <- #0 + PLEASE DO .5 <- #1$':1~"#32768$#0"' + DO (5107) NEXT + DO .5 <- '?"':1~:1'~#1"$#1'~#3 + DO (5107) NEXT + PLEASE STASH .1 + .2 + .3 + :1 + :3 + :4 + :6 + DO .1 <- :1~'#30720$#61440' + DO :1 <- '"':1~"#2047$#0"'$#2048"~"#2047$#2048"'$':1~"#0$#4095"' + DO .2 <- #897 + DO (1000) NEXT + DO .5 <- '?".3~#1"$#1'~#3 + DO (5101) NEXT + DO :1 <- ':1~"#0$#65535"'$'"':1~"#32767$#0"'$#0"~"#32767$#1"' + DO (5102) NEXT +(5101) DO (1001) NEXT +(5102) PLEASE FORGET #1 + DO .1 <- .3~#65534 + DO :6 <- :1 + DO :4 <- #0 + DO :1 <- #0 + DO .2 <- #4096 + DO (5104) NEXT +(5103) DO (1001) NEXT +(5104) PLEASE FORGET #1 + DO :1 <- '"':1~"#32767$#0"'$':6~"#0$.2"'"~"#32767$#1"'$ + '"':1~"#0$#32767"'$':6~"'.2~#65534'$#0"'"~"#32767$#1"' + DO :2 <- '"':4~"#32767$#0"'$#0"~"#32767$#1"'$'"':4~"#0$ + #32767"'$#1"~"#32767$#1"' + PLEASE DO (1510) NEXT + DO .5 <- '?":3~'#32768$#0'"$#1'~#3 + DO (5105) NEXT + DO :3 <- :1 + DO (5106) NEXT +(5105) DO (1001) NEXT +(5106) PLEASE FORGET #1 + DO :1 <- :3 + DO :4 <- ':4~"#0$#65535"'$'"':4~"#32767$#0"'$.5"~"#32767$#1"' + DO .2 <- .2~#65534 + DO (1020) NEXT + PLEASE DO .5 <- '?":4~'#0$#4096'"$#1'~#3 + DO (5103) NEXT + DO .2 <- #102 + DO (1000) NEXT + DO :1 <- :4 + DO :6 <- #1 + DO (5510) NEXT + DO :2 <- :1~'#65535$#65534' + PLEASE DO :2 <- '"'"'"'".3$':2~#32768'"~"#1109$#1"'$ + ':2~#128'"~#2735'$':2~"#546$#0"'"~"#43679"'$':2~"#1365$ + #0"'"~"#1023$#63"'$'"'"'".3$#0"~#34959'$':2~"#0$ + #1170"'"~#11007'$':2~"#0$#2925"'"~"#2005$#255"' + DO .5 <- #1 + PLEASE RETRIEVE .1 + .2 + .3 + :1 + :3 + :4 + :6 + PLEASE RESUME #1 +(5107) DO (1001) NEXT + PLEASE RESUME #2 + +(5110) DO :2 <- #32678$#0 + PLEASE DO .5 <- '?"?'?"':1~:1'~#1"$"#1$'":1~'#32768$ + #0'"~#1'"'"'~#5 + DO (5121) NEXT + PLEASE STASH .1 + :1 + DO .1 <- :1~'#30720$#61440' + DO :1 <- '"':1~"#2047$#0"'$#2048"~"#2047$#2048"'$':1~"#0$#4095"' + DO :2 <- #0 + DO (5610) NEXT + PLEASE DO (5600) NEXT + DO :2 <- :1 + PLEASE RETRIEVE .1 + :1 + DO RESUME #1 + +(5120) PLEASE STASH .1 + .4 + :1 + DO :2 <- #30720$#28672 + DO .4 <- #1 + DO .5 <- '?"':1~":1~'#32767$#65535'"'~#1"$#1'~#3 + DO (5121) NEXT + DO .1 <- :1~'#30720$#61440' + DO .5 <- '?.1$#100'~'#0$#65535' + DO .5 <- '?"!1~.5'~'"?.5~.5"~#32767'"$#1'~#3 + DO (5121) NEXT + DO :2 <- #0 + DO .4 <- #1$'"?':1~"#32768$#0"'$#1"~#1' + DO .5 <- '?.1$#133'~'#0$#65535' + DO .5 <- '?"!1~.5'~'"?.5~.5"~#32767'"$#2'~#3 + DO (5121) NEXT + PLEASE DO .1 <- '"'":1~'#63488$#61440'"$#256'~'#511$#256'"$ + #0'~'#1023$#256' + PLEASE DO :1 <- '"'"':1~"#0$#4095"'$#0"~"#4095$#1"'$#0"~"#8191$ + #3"'$'"'"':1~"#2047$#1"'$#32768"~"#4094$#32771"'$ + #0"~"#16383$#3"' + DO :2 <- #0 + DO (5620) NEXT + PLEASE DO (5600) NEXT + DO :2 <- :1 + DO (5122) NEXT +(5121) DO (1001) NEXT + DO .5 <- .4 +(5122) PLEASE RETRIEVE .1 + .4 + :1 + PLEASE RESUME #2 + +(5130) PLEASE STASH .3 + :1 + :2 + DO :3 <- #0 + DO .3 <- #1$'"?'":2~':2~"#32767$#65535"'"~#1'$#1"~#1' + DO .5 <- '?"':1~":1~'#32767$#65535'"'~#1"$#1'~#3 + DO (5131) NEXT + DO :3 <- #30720$#28672 + DO .5 <- '?".3~#1"$#2'~#3 + DO .3 <- #1 + DO (5131) NEXT + PLEASE DO .5 <- '?"&'?"'#127~":1~'#30720$#28672'"'~#64"$ + "'"#4095$#8191"~":1~'#34815$#36863'"'~#1"'~#3"$#2'~#3 + DO (5131) NEXT + DO (5650) NEXT + DO :3 <- #0 + DO .3 <- #3 + DO (5131) NEXT + PLEASE DO (5600) NEXT + DO :3 <- :1 + DO (5132) NEXT +(5131) DO (1001) NEXT + DO .5 <- .3 +(5132) PLEASE RETRIEVE .3 + :1 + :2 + PLEASE RESUME #2 + +(5200) PLEASE STASH .1 + :1 + :3 + :4 + DO (5670) NEXT + DO (5680) NEXT + DO .5 <- '?":1~'#32768$#0'"$#1'~#3 + DO (5201) NEXT + DO (5560) NEXT + DO .1 <- #1656 + DO (5202) NEXT +(5201) DO (1001) NEXT + DO .1 <- #632 +(5202) PLEASE DO (5600) NEXT + DO :2 <- :1 + PLEASE RETRIEVE .1 + :1 + :3 + :4 + PLEASE RESUME #2 + +(5210) PLEASE STASH .1 + :1 + :3 + :4 + DO (5670) NEXT + DO (5680) NEXT + DO :1 <- :3 + DO :2 <- :4 + DO .5 <- '?":1~'#32768$#0'"$#1'~#3 + DO (5211) NEXT + DO (5560) NEXT + DO .1 <- !1$#632'~'#2048$#1023' + DO (5212) NEXT +(5211) DO (1001) NEXT + DO .1 <- !1$#632'~'#1024$#1023' +(5212) PLEASE DO (5600) NEXT + DO :2 <- :1 + PLEASE RETRIEVE .1 + :1 + :3 + :4 + PLEASE RESUME #2 + +(5220) PLEASE STASH .1 + .2 + .3 + :1 + :3 + :4 + DO (5670) NEXT + DO (5680) NEXT + DO .2 <- #3 + DO .5 <- '?"'V"':3~:3'~#1"$"':4~:4'~#1"'~#1"$#1'~#3 + DO (5225) NEXT + DO .2 <- #1 + DO .5 <- '?"'V"':1~:1'~#1"$"':2~:2'~#1"'~#1"$#1'~#3 + DO (5225) NEXT + DO .2 <- .1 + DO .5 <- '?":1~'#32768$#0'"$#1'~#3 + DO (5221) NEXT + DO (5560) NEXT + DO .1 <- #1536 + DO (5222) NEXT +(5221) DO (1001) NEXT + DO .1 <- #512 +(5222) DO (5570) NEXT + PLEASE STASH .1 + :1 + :2 + DO :1 <- :3 + DO :2 <- :4 + DO .5 <- '?":1~'#32768$#0'"$#1'~#3 + DO (5223) NEXT + DO (5560) NEXT + DO .1 <- .2~#3071 + DO (5224) NEXT +(5223) DO (1001) NEXT + DO .1 <- .2~#2047 +(5224) PLEASE FORGET #2 + DO (5570) NEXT + DO :3 <- :1~'#65535$#65534' + PLEASE DO :4 <- '"'V:1~#1'$':2~"#0$#65534"'"~"#32768$#32767"'$ + ':2~"#65535$#0"' + DO .2 <- .1 + PLEASE RETRIEVE .1 + :1 + :2 + DO (1010) NEXT + DO .2 <- .3 + DO (5540) NEXT + PLEASE DO :2 <- '&"V:1~#64"'$'"':1~#63'$.5"~#2735' + DO :1 <- :1~'#65528$#65520' + DO (1009) NEXT + DO .1 <- .3~#2047 + PLEASE DO (5600) NEXT + DO :2 <- :1 + DO (5226) NEXT +(5225) DO (1001) NEXT + PLEASE DO :2 <- '&"V'?"!1~#3072'~'"?':3~"#32768$#0"'$#1"~#3'"$ + ":1~'#32768$#0'"'~#1"'$#0 + DO .5 <- .2 +(5226) PLEASE RETRIEVE .1 + .2 + .3 + :1 + :3 + :4 + PLEASE RESUME #2 + +(5400) PLEASE STASH .5 + :2 + :6 + DO :2 <- #0$#2048 + DO :1 <- #28672$#28672 + DO (5401) NEXT +(5403) DO (1001) NEXT +(5401) PLEASE FORGET #1 + DO %50 (5402) NEXT + DO :6 <- #2048$#0 + PLEASE DO (5519) NEXT + DO .5 <- '?"':1~:1'~#1"$#2'~#3 + DO (5403) NEXT + DO (5402) NEXT +(5404) DO (1001) NEXT +(5402) PLEASE FORGET #1 + DO %50 :1 <- '"V':1~"#65535$#0"'$':2~"#65535$#0"'"~"#0$#65535"'$ + '"V':1~"#0$#65535"'$':2~"#0$#65535"'"~"#0$#65535"' + DO :2 <- :2~'#65535$#65534' + DO .5 <- '?":2~:2"$#2'~#3 + DO (5404) NEXT + PLEASE RETRIEVE .5 + :2 + :6 + PLEASE RESUME #1 + +(5419) PLEASE ABSTAIN FROM (5411) +(5410) DO STASH .1 + :1 + :3 + :4 + DO .1 <- '"'":1~'#63488$#61440'"$#256'~'#511$#256'"$#0'~'#1023$ + #256' + DO :1 <- '"':1~"#2047$#0"'$#2048"~"#2047$#2048"'$':1~"#0$#4095"' + DO :2 <- #0 + PLEASE DO :3 <- #46058$#46446 + PLEASE DO :4 <- #64627$#29537 +(5411) DO :3 <- :3~'#32767$#65535' + DO (5530) NEXT + DO (1020) NEXT + PLEASE DO (5600) NEXT + DO :2 <- :1 + PLEASE REINSTATE (5411) + DO RETRIEVE .1 + :1 + :3 + :4 + DO RESUME #1 + +(5500) PLEASE STASH :1 + :3 + :4 + :5 + :6 + DO :1 <- :4 + DO (1509) NEXT + DO :5 <- :3 + PLEASE RETRIEVE :1 + :3 + DO :2 <- :3 + DO .5 <- :4 + DO (5501) NEXT + DO :6 <- #1 + DO (5510) NEXT + DO .5 <- '?"':1~:1'~#1"$#2'~#3 + DO (5501) NEXT + PLEASE DO :4 <- #1 + DO (5502) NEXT +(5501) DO (1001) NEXT + DO (1509) NEXT +(5502) DO :1 <- :3 + DO :3 <- :2 + DO :2 <- :5 + DO .5 <- :4 + PLEASE RETRIEVE :4 + :5 + :6 + PLEASE RESUME #2 + +(5510) PLEASE ABSTAIN FROM (5513) +(5519) DO STASH .5 + DO (5511) NEXT +(5511) PLEASE FORGET #1 + DO .5 <- '?":1~:6"$#1'~#3 + DO :1 <- '"?':1~"#65535$#0"'$':6~"#65535$#0"'"~"#0$#65535"'$ + '"?':1~"#0$#65535"'$':6~"#0$#65535"'"~"#0$#65535"' +(5513) DO .5 <- '?":1~:6"$#1'~#3 + DO (5512) NEXT + DO :6 <- ':6~"#0$#65535"'$'"':6~"#32767$#0"'$#0"~"#32767$#1"' + DO (5511) NEXT +(5512) DO (1001) NEXT + DO RETRIEVE .5 + PLEASE REINSTATE (5513) + PLEASE RESUME #2 + +(5520) PLEASE STASH .2 + .5 + DO .2 <- #1 + DO (5521) NEXT +(5521) PLEASE FORGET #1 + DO .1 <- '?.1$.2'~'#0$#65535' + DO .5 <- '?".1~.2"$#1'~#3 + DO (5522) NEXT + DO .2 <- !2$#0'~'#32767$#1' + DO (5521) NEXT +(5522) DO (1001) NEXT + PLEASE RETRIEVE .2 + .5 + PLEASE RESUME #2 + +(5530) PLEASE STASH .1 + .5 + :6 + :7 + :8 + :9 + :10 + :11 + :12 + + :13 + :14 + DO .1 <- #0 + DO :6 <- #0 + PLEASE DO :7 <- :1 + DO :8 <- :2 + DO :9 <- :3 + DO :10 <- :4 + PLEASE DO :11 <- #0 + DO :12 <- #0 + DO :13 <- #0 + DO :14 <- #0 + DO (5534) NEXT +(5533) DO (1001) NEXT +(5534) PLEASE FORGET #1 + DO .5 <- '?":10~#1"$#1'~#3 + DO (5536) NEXT + PLEASE DO :1 <- :13 + DO :2 <- :14 + DO :3 <- :7 + DO :4 <- :8 + DO (5500) NEXT + PLEASE DO (5532) NEXT + DO (1020) NEXT + DO (5531) NEXT +(5532) DO (1001) NEXT +(5531) PLEASE FORGET #1 + DO :13 <- :1 + DO :14 <- :2 + PLEASE DO :1 <- :11 + DO :2 <- :12 + DO :3 <- #0 + DO :4 <- :6 + DO (5500) NEXT + DO :11 <- :1 + DO :12 <- :2 + DO (5537) NEXT +(5536) DO (1001) NEXT +(5537) PLEASE FORGET #1 + DO .5 <- '?":9~#1"$#1'~#3 + DO (5538) NEXT + DO :1 <- :12 + DO :2 <- :13 + DO :3 <- :7 + DO :4 <- :8 + DO (5500) NEXT + DO :12 <- :1 + DO :13 <- :2 + PLEASE DO :1 <- :11 + DO :2 <- :6 + DO :6 <- .5~#2 + DO (5510) NEXT + DO (1500) NEXT + DO :11 <- :3 + DO :6 <- :2 + DO (5539) NEXT +(5538) DO (1001) NEXT +(5539) PLEASE FORGET #1 + DO :6 <- ':6~"#0$#65535"'$'"':6~"#32767$#0"'$':7~"#32768$ + #0"'"~"#32767$#1"' + DO :7 <- ':7~"#0$#65535"'$'"':7~"#32767$#0"'$':8~"#32768$ + #0"'"~"#32767$#1"' + DO :8 <- ':8~"#0$#65535"'$'"':8~"#32767$#0"'$#0"~"#32767$#1"' + PLEASE DO :9 <- :9~'#65535$#65534' + DO :10 <- :10~'#65535$#65534' + DO .5 <- '?"'V"':9~:9'~#1"$"':10~:10'~#1"'~#1"$#2'~#3 + DO (5533) NEXT + PLEASE DO :1 <- :11 + DO :2 <- :12 + DO :3 <- #0 + DO :4 <- .1 + DO (5500) NEXT + DO :3 <- :13 + DO :4 <- :14 + PLEASE RETRIEVE .1 + .5 + :6 + :7 + :8 + :9 + :10 + :11 + :12 + + :13 + :14 + PLEASE RESUME #1 + +(5540) PLEASE STASH :2 + :3 + :4 + :5 + :6 + DO :5 <- :1 + DO :6 <- :2 + PLEASE DO :1 <- :3 + DO :2 <- :4 + DO (5560) NEXT + DO :3 <- :1 + DO :4 <- :2 + DO :2 <- :6 + DO :6 <- #0 + DO .1 <- #156 + DO (5543) NEXT +(5543) PLEASE FORGET #1 + DO .5 <- '?":6~'#0$#32768'"$#2'~#3 + DO (5544) NEXT + DO .5 <- '?":5~'#32768$#0'"$#1'~#3 + DO (5545) NEXT + DO :1 <- :5 + DO (5500) NEXT + DO :5 <- :1 + DO :1 <- :6 + DO :6 <- #1 + DO (5510) NEXT + DO :6 <- :1 + DO (5543) NEXT +(5545) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE DO :5 <- ':5~"#0$#65535"'$'"':5~"#32767$#0"'$':2~"#32768$ + #0"'"~"#32767$#1"' + DO :2 <- ':2~"#0$#65535"'$'"':2~"#32767$#0"'$#0"~"#32767$#1"' + DO :6 <- ':6~"#0$#65535"'$'"':6~"#32767$#0"'$#0"~"#32767$#1"' + DO (5520) NEXT + DO (5543) NEXT +(5544) DO (1001) NEXT +(5546) PLEASE FORGET #1 + PLEASE DO .5 <- '?"'V"':5~:5'~#1"$"':2~:2'~#1"'~#1"$#1'~#3 + DO (5541) NEXT + DO :1 <- :5 + DO (5500) NEXT + DO :5 <- :1 + PLEASE DO :1 <- :6 + DO (5547) NEXT + DO :6 <- #1 + DO (5510) NEXT + DO :6 <- :1 + DO (5546) NEXT +(5541) DO (1001) NEXT + PLEASE DO .5 <- #0 + DO (5549) NEXT +(5547) DO (1001) NEXT + DO :6 <- '"?':5~"#32767$#0"'$':3~"#0$#65534"'"~"#0$#32767"'$ + '"?':5~"#0$#65535"'$':3~"#65535$#0"'"~"#0$#65535"' + DO .5 <- '?"':6~:6'~#1"$#1'~#3 + DO (5548) NEXT + DO .5 <- '":5~:6"~"'?:6~:6'~'#32767$#65535'"'$#1 + DO (5549) NEXT +(5548) DO (1001) NEXT + PLEASE DO :4 <- '"'V:3~#1'$':4~"#0$#65534"'"~"#32768$#32767"'$ + ':4~"#65535$#0"' + DO :6 <- '"?':2~"#65535$#0"'$':4~"#65535$#0"'"~"#0$#65535"'$ + '"?':2~"#0$#65535"'$':4~"#0$#65535"'"~"#0$#65535"' + DO .5 <- '?"':6~:6'~#1"$#1'~#3 + PLEASE DO .5 <- '"V'#3~"'"':2~:6'~'"?:6~:6"~"#32767$ + #65535"'"~#1'$'"':2~"#32768$#0"'~'":6~:6"~"#32768$ + #0"'"~#1'"'$!5~#1'"~#1'$!5~#2' +(5549) PLEASE RETRIEVE :2 + :3 + :4 + :5 + :6 + PLEASE RESUME #3 + +(5550) PLEASE STASH .5 + :1 + :2 + :3 + :4 + :5 + :6 + :7 + DO :5 <- :3 + DO :6 <- :4 + PLEASE DO :1 <- :3 + DO :2 <- :4 + DO (5560) NEXT + DO :3 <- :1 + DO :4 <- :2 + PLEASE RETRIEVE :1 + :2 + DO (1020) NEXT + DO (5551) NEXT +(5554) DO (1001) NEXT +(5552) PLEASE FORGET #1 + DO :7 <- '"?':5~"#65535$#0"'$':1~"#65535$#0"'"~"#0$#65535"'$ + '"?':5~"#0$#65535"'$':1~"#0$#65535"'"~"#0$#65535"' + DO .5 <- '?"':7~:7'~#1"$#2'~#3 + DO (5558) NEXT + DO :7 <- '"?':6~"#65535$#0"'$':2~"#65535$#0"'"~"#0$#65535"'$ + '"?':6~"#0$#65535"'$':2~"#0$#65535"'"~"#0$#65535"' + DO .5 <- '?"#3~'"'":6~:7"~"'?:7~:7'~'#32767$#65535'"'~#1"$ + "'":7~'#32768$#0'"~"':7~:7'~'#32768$#0'"'~#1"'"$#2'~#3 + DO (5559) NEXT +(5558) DO (1001) NEXT + DO .5 <- '?"#3~'"'":5~:7"~"'?:7~:7'~'#32767$#65535'"'~#1"$ + "'":7~'#32768$#0'"~"':7~:7'~'#32768$#0'"'~#1"'"$#2'~#3 +(5559) PLEASE FORGET #1 + DO (5555) NEXT + DO (5500) NEXT + DO (5552) NEXT +(5555) DO (1001) NEXT +(5557) PLEASE FORGET #1 + DO :1 <- ':1~"#0$#65535"'$'"':1~"#32767$#0"'$':2~"#32768$ + #0"'"~"#32767$#1"' + DO :2 <- ':2~"#0$#65535"'$'"':2~"#32767$#0"'$#0"~"#32767$#1"' + DO (5520) NEXT +(5551) DO .5 <- '?"'#65535~"'?.1$.2'~#21845"'~#1"$#2'~#3 + DO (5554) NEXT + PLEASE RETRIEVE .5 + :3 + :4 + :5 + :6 + :7 + PLEASE RESUME #2 + +(5560) PLEASE STASH .5 + :3 + :6 + DO .5 <- '?"':2~:2'~#1"$#1'~#3 + DO :6 <- #1 + DO (5561) NEXT + DO :3 <- '"?':1~"#65535$#0"'$#65535"~"#0$#65535"'$'"?':1~"#0$ + #65535"'$#65535"~"#0$#65535"' + DO :1 <- '"?':2~"#65535$#0"'$#65535"~"#0$#65535"'$'"?':2~"#0$ + #65535"'$#65535"~"#0$#65535"' + DO (5510) NEXT + DO :2 <- :1 + DO :1 <- :3 + DO (5562) NEXT +(5561) DO (1001) NEXT + DO :1 <- '"?':1~"#65535$#0"'$#65535"~"#0$#65535"'$'"?':1~"#0$ + #65535"'$#65535"~"#0$#65535"' + DO (5510) NEXT +(5562) PLEASE RETRIEVE .5 + :3 + :6 + PLEASE RESUME #2 + +(5570) DO .5 <- '?"'V"':1~:1'~#1"$"':2~:2'~#1"'~#1"$#2'~#3 + DO (1001) NEXT + DO (5571) NEXT +(5572) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE DO :1 <- ':1~"#0$#65535"'$'"':1~"#32767$#0"'$ + ':2~"#32768$#0"'"~"#32767$#1"' + DO :2 <- ':2~"#0$#65535"'$'"':2~"#32767$#0"'$#0"~"#32767$#1"' + DO (5520) NEXT +(5571) DO .5 <- '?":1~'#32768$#0'"$#1'~#3 + DO (5572) NEXT + DO .5 <- #1 + PLEASE RESUME #2 + +(5580) PLEASE STASH .1 + .5 + DO .1 <- .3 + DO (5581) NEXT +(5581) PLEASE FORGET #1 + DO .5 <- '?"!1~.1'~#1"$#1'~#3 + DO (5582) NEXT + DO :4 <- '"'V:3~#1'$':4~"#0$#65534"'"~"#32768$#32767"'$ + ':4~"#65535$#0"' + DO :3 <- '"':3~"#65535$#0"'$':3~"#0$#65534"'"~"#32768$#32767"'$ + ':3~"#65535$#0"' + DO (5520) NEXT + DO (5581) NEXT +(5582) DO (1001) NEXT + PLEASE RETRIEVE .1 + .5 + PLEASE RESUME #2 + +(5590) PLEASE STASH .2 + DO .2 <- #0 + DO .5 <- '?"'#255~":1~'#61440$#61440'"'~#1"$#2'~#3 + DO (5593) NEXT + DO (5591) NEXT +(5591) PLEASE FORGET #1 + DO .5 <- '?":1~'#2048$#0'"$#2'~#3 + DO (5592) NEXT + DO :1 <- ':1~"#0$#65535"'$'"':1~"#32767$#0"'$':2~"#32768$ + #0"'"~"#32767$#1"' + DO :2 <- ':2~"#0$#65535"'$'"':2~"#32767$#0"'$#0"~"#32767$#1"' + DO (5520) NEXT + DO (5591) NEXT +(5593) DO (1001) NEXT + PLEASE FORGET #1 + DO .2 <- '"V:2~#1"$.2'~'#32768$#32767' + DO :2 <- '"'V:1~#1'$':2~"#0$#65534"'"~"#32768$#32767"'$ + ':2~"#65535$#0"' + DO :1 <- :1~'#65535$#65534' + DO (1020) NEXT + DO .5 <- '?"'#255~":1~'#61440$#61440'"'~#1"$#2'~#3 + DO (5593) NEXT + DO (5594) NEXT +(5592) DO (1001) NEXT +(5594) DO .5 <- .2 + PLEASE RETRIEVE .2 + PLEASE RESUME #2 + +(5600) PLEASE DO .5 <- '?"'V"':1~:1'~#1"$"':2~:2'~#1"'~#1"$#1'~#3 + DO (5601) NEXT + DO STASH :6 + DO (5590) NEXT + DO :6 <- :2~'#32767$#65535' + PLEASE DO :6 <- 'V"'V"':6~:6'~#1"$"'.5~.5'~#1"'~#1"$ + ":1~#1"'~':2~"#32768$#0"' + DO (5510) NEXT + DO .5 <- '?"':1~"#61440$#61440"'~#1"$#1'~#3 + DO (5606) NEXT + PLEASE DO :1 <- #2048$#0 + DO (1020) NEXT + DO (5607) NEXT +(5601) DO (1001) NEXT + PLEASE RESUME #2 +(5606) DO (1001) NEXT +(5607) DO :2 <- #0 + PLEASE DO :1 <- '"'"'"'".1$':1~#32768'"~"#1109$#1"'$ + ':1~#128'"~#2735'$':1~"#546$#0"'"~"#43679"'$':1~"#1365$ + #0"'"~"#1023$#63"'$'"'"'".1$#0"~#34959'$':1~"#0$ + #1170"'"~#11007'$':1~"#0$#2925"'"~"#2005$#255"' + DO .5 <- !1~#256'$!1~#512' + DO RETRIEVE :6 + PLEASE RESUME #2 + +(5610) PLEASE STASH .2 + .3 + :3 + :4 + :5 + :6 + :7 + :8 + :9 + :10 + + :11 + :12 + ;1 + PLEASE DO (5691) NEXT + PLEASE DO :5 <- #4096$#0 + DO .2 <- .1~#255 + DO :7 <- :1 + DO :8 <- :2 + DO :1 <- #0 + DO :2 <- #0 + DO .1 <- #1 + DO (5612) NEXT +(5611) DO (1001) NEXT + PLEASE FORGET #1 + DO :3 <- '"?':7~"#65535$#0"'$#65535"~"#0$#65535"'$ + '"?':7~"#0$#65535"'$#65535"~"#0$#65535"' + DO :4 <- '"?':8~"#65535$#0"'$#65535"~"#0$#65535"'$ + '"?':8~"#0$#65535"'$#65535"~"#0$#65535"' + DO .3 <- .1 + DO (5580) NEXT + DO :9 <- :3 + DO :10 <- :4 + DO :11 <- :1 + DO :12 <- :2 + DO (5615) NEXT +(5616) DO (1001) NEXT + PLEASE FORGET #1 + DO (1020) NEXT + DO :5 <- :5~'#65535$#65534' + DO .5 <- '?":5~:5"$#2'~#3 + DO (5617) NEXT + DO :5 <- #0$#16384 + PLEASE ABSTAIN FROM (5638) + PLEASE ABSTAIN FROM (5639) + DO (5615) NEXT +(5617) DO (1001) NEXT +(5615) PLEASE FORGET #1 + DO :10 <- '"'V:9~#1'$':10~"#0$#65534"'"~"#32768$#32767"'$ + ':10~"#65535$#0"' + DO :9 <- '"':9~"#0$#65535"'$':9~"#0$#65534"'"~"#32768$#32767"'$ + ':9~"#65535$#0"' + DO :6 <- #1 + PLEASE DO .5 <- '?"':10~:10'~'#32768$#0'"$#2'~#3 + DO (5613) NEXT + DO :3 <- :9 + DO :1 <- :10 + DO (5510) NEXT + DO :4 <- :1 + DO (5614) NEXT +(5613) DO (1001) NEXT + DO :1 <- :9 + DO (5510) NEXT + DO :3 <- :1 + DO :4 <- #0 +(5614) PLEASE FORGET #1 + DO :1 <- :7 + DO :2 <- :8 + DO (5500) NEXT + DO .5 <- '?":1~'#2048$#0'"$#1'~#3 + DO (5616) NEXT + DO :7 <- :1 + DO :8 <- :2 + PLEASE DO :1 <- :11 + DO :2 <- :12 + DO :3 <- #0 + DO :4 <- :5 +(5638) PLEASE DO :3 <- ;1SUB.1#1 +(5639) PLEASE DO :4 <- ;1SUB.1#2 + DO (5500) NEXT +(5612) DO .5 <- '?"'V"':7~":7~'#2047$#4095'"'~#1"$"':8~:8'~#1"'~#1"$ + #2'~#3 + DO (5611) NEXT + DO .1 <- #638 + DO .5 <- '?"'#65535~"'?.2$#127'~#21845"'~#1"$#1'~#3 + DO (5619) NEXT + DO :11 <- :1 + DO :12 <- :2 + DO .1 <- .2 + DO .2 <- #127 + DO (1010) NEXT + DO .2 <- !3~#65280'$!3~#65280' + DO :1 <- '".2$.3"~"#65280$#61610"'$'".2$.3"~"#65280$#61525"' + PLEASE DO :2 <- #1479$#6307 + DO (1549) NEXT + DO :6 <- :3 + PLEASE DO :2 <- #4059$#2839 + DO (1549) NEXT + DO :1 <- :6 + DO :2 <- '".2$':3~"#61440$#0"'"~"#65520$#15"'$'".2$':3~"#0$ + #61440"'"~"#65520$#15"' + DO :6 <- '"'"'"':3~"#4095$#0"'$#0"~"#4095$#1"'$#0"~"#8191$#1"'$ + #0"~"#16383$#3"'$'"'"'"':3~"#0$#4095"'$#0"~"#4095$#1"'$ + #0"~"#8191$#1"'$#0"~"#16383$#3"' + DO (1509) NEXT + DO :4 <- '"'V:3~#1'$':6~"#0$#65534"'"~"#32768$#32767"'$ + ':6~"#65535$#0"' + PLEASE DO :3 <- '".2$':3~"#0$#65534"'"~"#32768$#32767"'$ + ':3~"#65535$#0"' + DO :1 <- :11 + DO :2 <- :12 + DO (5500) NEXT + DO .1 <- #638 + DO .5 <- '?".2~#1"$#1'~#3 + DO (5619) NEXT + DO .1 <- #1662 + DO (5560) NEXT + DO (5618) NEXT +(5619) DO (1001) NEXT +(5618) PLEASE REINSTATE (5638) + PLEASE REINSTATE (5639) + PLEASE RETRIEVE .2 + .3 + :3 + :4 + :5 + :6 + :7 + :8 + :9 + + :10 + :11 + :12 + ;1 + PLEASE RESUME #3 + +(5620) PLEASE STASH .2 + .3 + :3 + :4 + :6 + :7 + :8 + :9 + :10 + ;1 + PLEASE DO (5692) NEXT + PLEASE DO :3 <- #61302$#16465 + PLEASE DO :4 <- #8654$#59334 + DO (5530) NEXT + DO :3 <- :1 + DO :4 <- :2 + DO .4 <- !1~#1024'$#1 + DO .2 <- .1~#1023 + DO .1 <- #636 + DO (1010) NEXT + DO .1 <- .3 + DO .2 <- #0 + DO .5 <- '?".1~#32768"$#1'~#3 + DO (5635) NEXT + DO (5624) NEXT +(5625) DO (1001) NEXT +(5624) PLEASE FORGET #1 + DO .2 <- !2$":3~'#32768$#0'"'~'#32767$#1' + DO :3 <- ':3~"#0$#65535"'$'"':3~"#32767$#0"'$':4~"#32768$ + #0"'"~"#32767$#1"' + DO :4 <- ':4~"#0$#65535"'$'"':4~"#32767$#0"'$#0"~"#32767$#1"' + DO (1020) NEXT + DO .5 <- '?"!1~.1'~#1"$#2'~#3 + DO (5625) NEXT + DO (5623) NEXT +(5635) DO (1001) NEXT + DO (5580) NEXT +(5623) PLEASE FORGET #1 + PLEASE DO .5 <- .?4~#3 + DO .4 <- .2 + DO (5626) NEXT + PLEASE DO .4 <- '?.4$#65535'~'#0$#65535' + DO :6 <- #1 + DO .5 <- '?"':4~:4'~#1"$#1'~#3 + DO (5627) NEXT + DO :1 <- '"?':4~"#65535$#0"'$#65535"~"#0$#65535"'$'"?':4~"#0$ + #65535"'$#65535"~"#0$#65535"' + DO (5510) NEXT + DO :4 <- :1 + DO :3 <- '"?':3~"#65535$#0"'$#65535"~"#0$#65535"'$'"?':3~"#0$ + #65535"'$#65535"~"#0$#65535"' + DO (5628) NEXT +(5627) DO (1001) NEXT + PLEASE DO .5 <- '?"':3~:3'~#1"$#1'~#3 + DO (5622) NEXT + PLEASE FORGET #1 + DO :1 <- '"?':3~"#65535$#0"'$#65535"~"#0$#65535"'$'"?':3~"#0$ + #65535"'$#65535"~"#0$#65535"' + DO (5510) NEXT + DO :3 <- :1 + DO :4 <- #0 + DO (5628) NEXT +(5622) DO (1001) NEXT + PLEASE FORGET #2 + DO .1 <- .4 + PLEASE DO (1020) NEXT + DO .4 <- .1 + DO :3 <- #0 + DO :4 <- #0 + DO (5628) NEXT +(5626) DO (1001) NEXT +(5628) PLEASE FORGET #1 + PLEASE DO :1 <- #50461$#23679 + PLEASE DO :2 <- #35694$#56274 + DO (5530) NEXT + DO :7 <- :1 + DO :8 <- :2 + PLEASE DO :9 <- #2048$#0 + DO :10 <- #0 + DO :6 <- #0 + DO .1 <- #1 + DO :1 <- :9 + DO :2 <- :10 + DO (5621) NEXT +(5629) DO (1001) NEXT + PLEASE FORGET #1 + DO .5 <- '?":6~:6"$#1'~#3 + DO (5631) NEXT + DO :2 <- :6 + DO :1 <- :8 + PLEASE DO (5519) NEXT + DO .5 <- '?":6~:6"$#1'~#3 + DO :6 <- :2~'#65535$#65534' + DO :2 <- :1 + DO :1 <- #0 + DO (5632) NEXT +(5631) DO (1001) NEXT + DO .5 <- '?".1~#32"$#1'~#3 + DO (5633) NEXT + DO :6 <- #32768$#0 + DO (5634) NEXT +(5633) DO (1001) NEXT +(5634) PLEASE FORGET #1 + DO :1 <- :7 + DO :2 <- :8 + DO :3 <- ;1SUB.1#1 + DO :4 <- ;1SUB.1#2 + DO (5500) NEXT +(5632) PLEASE FORGET #1 + DO .3 <- .1 + DO (1020) NEXT + DO (5629) NEXT + DO :7 <- :1 + DO :8 <- :2 + PLEASE DO :1 <- :9 + DO :2 <- :10 + DO :3 <- :1 + DO :4 <- :2 + DO (5580) NEXT + DO (5500) NEXT + DO :9 <- :1 + DO :10 <- :2 +(5621) DO .5 <- '?"'V"':7~:7'~#1"$"':8~:8'~#1"'~#1"$#2'~#3 + DO (5629) NEXT + PLEASE DO .1 <- .4 + DO .2 <- #639 + DO (1009) NEXT + DO .1 <- .3 + PLEASE RETRIEVE .2 + :3 + :4 + :6 + :7 + :8 + :9 + :10 + ;1 + PLEASE RESUME #2 + +(5640) PLEASE STASH .2 + .3 + .4 + .7 + .8 + :3 + :4 + :5 + :6 + :7 + + :8 + :9 + DO :5 <- :3 + DO :7 <- :1 + DO :8 <- :2 + DO .5 <- '?":5~'#32768$#0'"$#1'~#3 + PLEASE DO .8 <- !5$"V':5~".1~#1024"'~#1"'~'#1023$#32768' + DO .1 <- .1~#511 + DO .2 <- #65410 + DO (1009) NEXT + DO .4 <- .3 + DO (5643) NEXT + DO :1 <- '"?':5~"#65535$#0"'$#65535"~"#0$#65535"'$'"?':5~"#0$ + #65535"'$#65535"~"#0$#65535"' + DO :6 <- #1 + DO (5510) NEXT + DO :5 <- :1 + DO (5644) NEXT +(5643) DO (1001) NEXT +(5644) PLEASE FORGET #1 + PLEASE DO :6 <- #32768$#0 + DO :9 <- #0 + DO .7 <- #631 + DO (5642) NEXT +(5642) PLEASE FORGET #1 + DO .5 <- '?":5~#1"$#1'~#3 + DO (5645) NEXT + DO .5 <- .2 + PLEASE DO .1 <- .7 + DO .2 <- .4 + DO (1009) NEXT + DO .1 <- .3 + DO .4 <- .2 + DO .2 <- .5 + PLEASE DO :1 <- :6 + DO :2 <- :9 + DO :3 <- :7 + DO :4 <- :8 + PLEASE DO (5530) NEXT + DO (5570) NEXT + DO .7 <- .1 + DO :6 <- :1 + DO :9 <- :2 + DO .5 <- '?".5~#2"$#2'~#3 + DO (5646) NEXT + PLEASE DO .5 <- .7~#64512 + DO .5 <- '?"!5~.5'~#1"$#1'~#3 + DO (5645) NEXT + PLEASE DO .7 <- '"'?"V.8~#1"$.7'~'#0$#33279'"$#256'~'#767$#256' + DO (5649) NEXT +(5645) DO (1001) NEXT +(5647) PLEASE FORGET #1 + DO :5 <- :5~'#65535$#65534' + DO .5 <- '?"':5~:5'~#1"$#1'~#3 + DO (5646) NEXT + PLEASE DO :1 <- :7 + DO :2 <- :8 + DO :3 <- :7 + DO :4 <- :8 + DO .1 <- !4$#0'~'#32767$#1' + PLEASE DO (5530) NEXT + DO :4 <- :3~'#32768$#0' + DO :3 <- #0 + DO (5500) NEXT + DO (5570) NEXT + DO :7 <- :1 + DO :8 <- :2 + DO .4 <- .1 + DO (5642) NEXT +(5646) DO (1001) NEXT + PLEASE FORGET #1 + DO .5 <- .8~#3 + DO (5648) NEXT + DO .1 <- #119 + DO .2 <- .7 + DO (1010) NEXT + DO :3 <- :6~'#65535$#65534' + PLEASE DO :4 <- '"':9~"#0$#65534"'$'V:6~#1'"~"#32767$#1"'$ + ':9~"#65535$#0"' + DO :1 <- #32768$#0 + DO :2 <- #0 + PLEASE DO (5540) NEXT + DO :2 <- '"'"'"'"'"'":1~#127"$#0'~#10923"$.5'~#43693"$#0'~'#511$ + #1'"$#0'~'#1023$#3'"$#0'~'#4095$#15'"$#0'~'#65535$#31' + PLEASE DO :2 <- ':2~"#31$#2047"'$':2~"#1023$#63"' + DO :1 <- :1~'#65528$#65520' + DO .2 <- .3 + DO (1009) NEXT + DO .7 <- .3 + DO (5649) NEXT +(5648) DO (1001) NEXT + DO :1 <- :6 + DO :2 <- :9 +(5649) DO .1 <- !8$.7'~'#1024$#1023' + PLEASE RETRIEVE .2 + .3 + .4 + .7 + .8 + :3 + :4 + :5 + :6 + + :7 + :8 + :9 + PLEASE RESUME #2 + +(5650) PLEASE STASH .2 + .3 + .4 + .6 + .7 + .8 + :4 + :5 + :6 + + :7 + :8 + DO :5 <- :1 + DO .7 <- :2~'#32768$#0' + PLEASE DO .4 <- '"'":2~'#63488$#61440'"$#256'~'#511$#256'"$ + #0'~'#1023$#256' + DO .2 <- :2~'#30720$#61440' + DO :1 <- '"'"':2~"#2047$#1"'$#4096"~"#4094$#4099"'$#0"~"#16383$ + #3"'$'"'"'"':2~"#0$#4095"'$#0"~"#4095$#1"'$#0"~"#8191$ + #1"'$#0"~"#16383$#3"' + DO .1 <- #158 + DO (1010) NEXT + DO .1 <- .3 + PLEASE DO :3 <- '".V7$#32767"~"#32768$#32767"'$#65535 + DO :4 <- #0 + DO .5 <- '?".1~#32768"$#2'~#3 + DO (5665) NEXT + DO :3 <- #0 + DO :4 <- :2 + PLEASE DO .5 <- '?"'#65535~".1~#65504"'~#1"$#2'~#3 + DO (5665) NEXT + DO :4 <- #1 + DO (5662) NEXT +(5667) DO (1001) NEXT + PLEASE DO :4 <- :V4 + DO (5520) NEXT +(5662) PLEASE FORGET #1 + DO .5 <- '?"!1~.1'~#1"$#2'~#3 + DO (5667) NEXT + DO :4 <- ':4~"#65535$#65534"'~':4~"#65535$#65534"' + DO :3 <- :1~'"'?":4~'#65535$#0'"$#65535'~'#0$#65535'"$ + "'?":4~'#0$#65535'"$#65535'~'#0$#65535'"' + DO :1 <- ':1~:4'~'#65520$#65520' + DO :2 <- #0 + DO .1 <- '"!V7$#512'~'#32768$#1023'"$.2'~'#1536$#511' + DO (5600) NEXT + DO :4 <- :1 + DO (5656) NEXT +(5665) DO (1001) NEXT +(5656) PLEASE FORGET #1 + DO .5 <- '?"':5~"#32768$#0"'~'":4~:4"~#1'"$#2'~#3 + DO (5655) NEXT + DO .1 <- .2 + DO .5 <- '?"':3~:3'~#1"$#1'~#3 + DO (5651) NEXT + DO .6 <- #1 + PLEASE DO .1 <- '"'":5~'#63488$#61440'"$#256'~'#511$#256'" + $#0'~'#1023$#256' + DO :1 <- '"'"':5~"#2047$#1"'$#4096"~"#4094$#4099"'$#0"~"#16383$ + #3"'$'"'"'"':5~"#0$#4095"'$#0"~"#4095$#1"'$#0"~"#8191$ + #1"'$#0"~"#16383$#3"' + DO :2 <- #0 + PLEASE DO (5640) NEXT + DO (5570) NEXT + DO :7 <- :1 + DO :8 <- :2 + DO .8 <- .1 + DO (5652) NEXT +(5651) DO (1001) NEXT + DO .6 <- #0 +(5652) PLEASE FORGET #1 + DO .5 <- '?"':4~:4'~#1"$#1'~#3 + DO (5653) NEXT + DO .6 <- #1$.6 + DO .1 <- :5~'#30720$#61440' + DO :1 <- '"':5~"#2047$#0"'$#2048"~"#2047$#2048"'$':5~"#0$#4095"' + DO :2 <- #0 + PLEASE DO (5610) NEXT + DO (5570) NEXT + PLEASE DO .2 <- '"'":4~'#63488$#61440'"$#0'~'#511$#256'"$ + #0'~'#1023$#256' + DO :3 <- '"'"':4~"#2047$#1"'$#4096"~"#4094$#4099"'$#0"~"#16383$ + #3"'$'"'"'"':4~"#0$#4095"'$#0"~"#4095$#1"'$#0"~"#8191$ + #1"'$#0"~"#16383$#3"' + DO :4 <- #0 + PLEASE DO (5530) NEXT + DO .5 <- '?":1~'#32768$#0'"$#1'~#3 + DO (5663) NEXT + PLEASE DO :2 <- '"'V:1~#1'$':2~"#0$#65534"'"~"#32768$#32767"'$ + ':2~"#65535$#0"' + DO :1 <- :1~'#65535$#65534' + DO (1020) NEXT + DO (5664) NEXT +(5663) DO (1001) NEXT +(5664) PLEASE FORGET #1 + DO (1000) NEXT + DO .1 <- .3 + DO .2 <- #119 + DO (1010) NEXT + DO .1 <- .3 + PLEASE DO (5620) NEXT + DO (5570) NEXT + DO (5654) NEXT +(5653) DO (1001) NEXT +(5654) PLEASE FORGET #1 + DO .5 <- .6 + PLEASE DO (5659) NEXT + DO .5 <- '?.7$#1'~#3 + DO (5657) NEXT + DO .2 <- .8 + DO (1010) NEXT + DO .2 <- .3~#2047 + DO :3 <- :7~'#65535$#65534' + PLEASE DO :4 <- '"'V:7~#1'$':8~"#0$#65534"'"~"#32768$#32767"'$ + ':8~"#65535$#0"' + PLEASE DO (5540) NEXT + DO (1009) NEXT + DO .1 <- .3 + PLEASE DO :2 <- '&"V:1~#64"'$'"':1~#63'$.5"~#2735' + DO :1 <- :1~'#65528$#65520' + DO .5 <- #2 + DO (5658) NEXT +(5657) DO (1001) NEXT + PLEASE FORGET #1 + DO :3 <- :7 + DO :4 <- :8 + PLEASE DO (5530) NEXT + DO .2 <- #630 + DO (1010) NEXT + DO .1 <- .3 + DO .2 <- .8 + DO (1009) NEXT + DO .1 <- .3~#2047 + DO .5 <- #2 + DO (5658) NEXT +(5661) DO (1001) NEXT + PLEASE FORGET #2 + DO .5 <- '?.7$#1'~#3 + DO (5666) NEXT + DO .1 <- #1399 + DO .2 <- .8 + DO (1010) NEXT + DO .2 <- .3~#2047 + DO :1 <- #32768$#0 + DO :2 <- #0 + DO :3 <- :7~'#65535$#65534' + DO :4 <- '"'V:7~#1'$':8~"#0$#65534"'"~"#32768$#32767"'$ + ':8~"#65535$#0"' + PLEASE DO (5540) NEXT + DO (1009) NEXT + DO .1 <- .3 + PLEASE DO :2 <- '&"V:1~#64"'$'"':1~#63'$.5"~#2735' + DO :1 <- :1~'#65528$#65520' + DO .5 <- #2 + DO (5658) NEXT +(5666) DO (1001) NEXT + PLEASE FORGET #1 + DO :1 <- :7 + DO :2 <- :8 + DO .1 <- .8 + PLEASE DO .5 <- #2 + DO (5658) NEXT +(5655) DO (1001) NEXT + PLEASE FORGET #1 + DO (5658) NEXT +(5659) DO (5661) NEXT +(5658) PLEASE RETRIEVE .2 + .3 + .4 + .6 + .7 + .8 + :4 + :5 + :6 + + :7 + :8 + PLEASE RESUME #2 + +(5670) PLEASE STASH .2 + .3 + .5 + :3 + :4 + DO .1 <- :1~'#30720$#61440' + DO .5 <- '?.1$#128'~#21845 + DO .5 <- '?"!1~.5'~'"?.5~.5"~#255'"$#1'~#3 + DO (5677) NEXT + DO .5 <- :1~'#32768$#0' + PLEASE DO :1 <- '"'"':1~"#0$#4095"'$#0"~"#4095$#1"'$#0"~"#8191$ + #3"'$'"'"':1~"#2047$#1"'$#32768"~"#4094$#32771"'$ + #0"~"#16383$#3"' + DO :2 <- #0 + DO .2 <- #129 + PLEASE DO :3 <- #18912$#41917 + PLEASE DO :4 <- #3139$#18068 + DO (5550) NEXT + DO .2 <- .5 + DO (5678) NEXT +(5677) DO (1001) NEXT + DO .2 <- .1 + DO .1 <- #129 + DO (1010) NEXT + DO .2 <- :1~'#32768$#0' + PLEASE DO :3 <- '"'"':1~"#0$#4095"'$#0"~"#4095$#1"'$#0"~"#8191$ + #3"'$'"'"':1~"#2047$#1"'$#32768"~"#4094$#32771"'$ + #0"~"#16383$#3"' + DO :4 <- #0 + DO (5580) NEXT + DO :1 <- ':3~"#0$#65535"'$'"':3~"#32767$#0"'$':4~"#32768$ + #0"'"~"#32767$#1"' + DO :2 <- ':4~"#0$#65535"'$'"':4~"#32767$#0"'$#0"~"#32767$#1"' +(5678) PLEASE FORGET #1 + PLEASE DO :3 <- '"?':1~"#65535$#0"'$#18912"~"#0$#65535"'$ + '"?':1~"#0$#65535"'$#41917"~"#0$#65535"' + DO .5 <- '?"#3~'"'":1~:3"~"'?:3~:3'~'#32767$#65535'"'~#1"$ + "'":1~'#32768$#0'"~"':3~:3'~'#32768$#0'"'~#1"'"$#1'~#3 + DO (5671) NEXT + DO (5560) NEXT + PLEASE DO :3 <- #41917$#37824 + PLEASE DO :4 <- #18068$#6279 + DO (5500) NEXT + DO .2 <- '?.2$#1'~#1 + DO (5672) NEXT +(5671) DO (1001) NEXT +(5672) PLEASE FORGET #1 + PLEASE DO :3 <- '"?':1~"#32767$#0"'$#20958"~"#0$#32767"'$ + '"?':1~"#0$#65535"'$#18913"~"#0$#65535"' + DO .5 <- '?"':1~:3'~'"?:3~:3"~"#32767$#65535"'"$#1'~#3 + DO (5673) NEXT + DO (5560) NEXT + PLEASE DO :3 <- #18912$#41917 + PLEASE DO :4 <- #3139$#18068 + DO (5500) NEXT + DO .1 <- #1024 + DO (5674) NEXT +(5673) DO (1001) NEXT + DO .1 <- #2048 +(5674) PLEASE FORGET #1 + DO :1 <- ':1~"#0$#65535"'$'"':1~"#32767$#0"'$':2~"#32768$ + #0"'"~"#32767$#1"' + DO :2 <- ':2~"#0$#65535"'$'"':2~"#32767$#0"'$#0"~"#32767$#1"' + DO .5 <- '?.2$#1'~#3 + DO (5675) NEXT + DO (5560) NEXT + DO (5676) NEXT +(5675) DO (1001) NEXT +(5676) PLEASE RETRIEVE .2 + .3 + .5 + :3 + :4 + PLEASE RESUME #2 + +(5680) PLEASE STASH .1 + .2 + .3 + .5 + :5 + :6 + :7 + :8 + :9 + :10 + + :11 + ;1 + DO .5 <- ':2~"#32768$#32768"'$'":1~:1"~"#32768$#1"' + PLEASE DO .5 <- '?"'?".5~.5"~#9'~#1"$#1'~#3 + DO (5681) NEXT + PLEASE DO (5693) NEXT + DO :5 <- :1 + DO :6 <- :2 + DO :7 <- #0 + DO :8 <- #0 + PLEASE DO :9 <- #23159$#12120 + PLEASE DO :10 <- #2459$#20324 + DO :11 <- #32768$#0 + DO .1 <- #0 + DO (5685) NEXT +(5685) PLEASE FORGET #1 + DO .3 <- .1 + DO (1020) NEXT + DO .5 <- '?".1~#32"$#1'~#3 + DO (5688) NEXT + DO :1 <- #0 + DO :2 <- :11 + DO :11 <- :11~'#65535$#65534' + PLEASE DO .5 <- '?"'V":1~:1"$":2~:2"'~':11~:11'"$#1'~#3 + DO (5683) NEXT + DO (5687) NEXT +(5688) DO (1001) NEXT + DO :1 <- ;1SUB.1#1 + DO :2 <- ;1SUB.1#2 +(5687) PLEASE FORGET #1 + DO :3 <- :5 + DO :4 <- :6 + DO .5 <- '?":5~'#32768$#0'"$#1'~#3 + DO (5684) NEXT + DO (5500) NEXT + DO :5 <- :1 + DO :6 <- :2 + PLEASE DO :1 <- :9 + DO :2 <- :10 + DO (5560) NEXT + DO :3 <- :1 + DO :4 <- :2 + PLEASE STASH :3 + :4 + DO :3 <- :7 + DO :4 <- :8 + DO (5686) NEXT +(5684) DO (1001) NEXT + DO (5560) NEXT + DO (5500) NEXT + DO :5 <- :1 + DO :6 <- :2 + DO :3 <- :9 + DO :4 <- :10 + PLEASE STASH :3 + :4 + DO :1 <- :7 + DO :2 <- :8 + DO (5560) NEXT + DO :3 <- :1 + DO :4 <- :2 +(5686) PLEASE FORGET #1 + PLEASE DO :1 <- :9 + DO :2 <- :10 + DO (5580) NEXT + DO (5500) NEXT + DO :9 <- :1 + DO :10 <- :2 + PLEASE RETRIEVE :3 + :4 + PLEASE DO :1 <- :7 + DO :2 <- :8 + DO (5580) NEXT + DO (5500) NEXT + DO :7 <- :1 + DO :8 <- :2 + DO .5 <- '?".1~#32"$#1'~#3 + DO (5685) NEXT +(5683) DO (1001) NEXT + PLEASE DO :1 <- :7 + DO :2 <- :8 + DO :3 <- :9 + DO :4 <- :10 + DO (5682) NEXT +(5681) DO (1001) NEXT + DO :3 <- #0$#32768 + DO :4 <- #0 + DO (5682) NEXT +(5682) PLEASE RETRIEVE .1 + .2 + .3 + .5 + :5 + :6 + :7 + :8 + :9 + + :10 + :11 + ;1 + PLEASE RESUME #3 + +(5690) PLEASE DO ;1 <- #39 + PLEASE DO ,1 <- #39 + DO ;1SUB#1 <- #49152$#0 + DO ,1SUB#1 <- #3 + PLEASE DO ;1SUB#2 <- #40960$#32768 + DO ,1SUB#2 <- #6 + DO ;1SUB#3 <- #61440$#49152 + DO ,1SUB#3 <- #9 + PLEASE DO ;1SUB#4 <- #40960$#26624 + DO ,1SUB#4 <- #13 + DO ;1SUB#5 <- #36864$#39936 + DO ,1SUB#5 <- #16 + PLEASE DO ;1SUB#6 <- #50176$#57856 + DO ,1SUB#6 <- #19 + DO ;1SUB#7 <- #43392$#17920 + DO ,1SUB#7 <- #23 + PLEASE DO ;1SUB#8 <- #65088$#26112 + DO ,1SUB#8 <- #26 + DO ;1SUB#9 <- #63328$#43264 + DO ,1SUB#9 <- #29 + PLEASE DO ;1SUB#10 <- #33248$#28880 + DO ,1SUB#10 <- #33 + DO ;1SUB#11 <- #61904$#18808 + DO ,1SUB#11 <- #36 + PLEASE DO ;1SUB#12 <- #59584$#36404 + DO ,1SUB#12 <- #39 + DO ;1SUB#13 <- #35031$#21168 + DO ,1SUB#13 <- #43 + PLEASE DO ;1SUB#14 <- #52556$#31247 + DO ,1SUB#14 <- #46 + DO ;1SUB#15 <- #54245$#40724 + DO ,1SUB#15 <- #49 + PLEASE DO ;1SUB#16 <- #45999$#9623 + DO ,1SUB#16 <- #53 + DO ;1SUB#17 <- #52711$#20579 + DO ,1SUB#17 <- #56 + PLEASE DO ;1SUB#18 <- #45943$#57748 + DO ,1SUB#18 <- #59 + DO ;1SUB#19 <- #47440$#2835 + DO ,1SUB#19 <- #63 + PLEASE DO ;1SUB#20 <- #59129$#15514 + DO ,1SUB#20 <- #66 + DO ;1SUB#21 <- #43357$#53031 + DO ,1SUB#21 <- #69 + PLEASE DO ;1SUB#22 <- #39269$#12996 + DO ,1SUB#22 <- #73 + DO ;1SUB#23 <- #58903$#6247 + DO ,1SUB#23 <- #76 + PLEASE DO ;1SUB#24 <- #39227$#55387 + DO ,1SUB#24 <- #79 + DO ;1SUB#25 <- #33284$#11737 + DO ,1SUB#25 <- #83 + PLEASE DO ;1SUB#26 <- #51151$#15156 + DO ,1SUB#26 <- #86 + DO ;1SUB#27 <- #48054$#43312 + DO ,1SUB#27 <- #89 + PLEASE DO ;1SUB#28 <- #34662$#5981 + DO ,1SUB#28 <- #93 + DO ;1SUB#29 <- #51993$#4927 + DO ,1SUB#29 <- #96 + PLEASE DO ;1SUB#30 <- #44458$#40091 + DO ,1SUB#30 <- #99 + DO ;1SUB#31 <- #59232$#60392 + DO ,1SUB#31 <- #102 + PLEASE DO ;1SUB#32 <- #43246$#31536 + DO ,1SUB#32 <- #106 + DO ;1SUB#33 <- #34081$#46932 + DO ,1SUB#33 <- #109 + PLEASE DO ;1SUB#34 <- #55473$#58111 + DO ,1SUB#34 <- #112 + DO ;1SUB#35 <- #45369$#17686 + DO ,1SUB#35 <- #116 + PLEASE DO ;1SUB#36 <- #35254$#34734 + DO ,1SUB#36 <- #119 + DO ;1SUB#37 <- #52883$#51077 + DO ,1SUB#37 <- #122 + PLEASE DO ;1SUB#38 <- #38304$#28253 + DO ,1SUB#38 <- #126 + DO ;1SUB#39 <- #57468$#26227 + DO ,1SUB#39 <- #129 + PLEASE RESUME #1 + +(5691) PLEASE DO ;1 <- #26 BY #2 + DO ;1SUB#1#1 <- #714$#2352 + DO ;1SUB#1#2 <- #2418$#44457 + PLEASE DO ;1SUB#2#1 <- #1394$#55 + DO ;1SUB#2#2 <- #943$#11147 + DO ;1SUB#3#1 <- #138$#1076 + DO ;1SUB#3#2 <- #52079$#30302 + PLEASE DO ;1SUB#4#1 <- #591$#2 + DO ;1SUB#4#2 <- #36307$#44292 + DO ;1SUB#5#1 <- #32$#519 + DO ;1SUB#5#2 <- #38032$#25317 + PLEASE DO ;1SUB#6#1 <- #273$#0 + DO ;1SUB#6#2 <- #64569$#9562 + DO ;1SUB#7#1 <- #8$#256 + DO ;1SUB#7#2 <- #2221$#63237 + PLEASE DO ;1SUB#8#1 <- #32800 + DO ;1SUB#8#2 <- #16352$#554 + DO ;1SUB#9#1 <- #16392 + DO ;1SUB#9#2 <- #133$#8056 + PLEASE DO ;1SUB#10#1 <- #8194 + DO ;1SUB#10#2 <- #2047$#33 + DO ;1SUB#11#1 <- #4096 + DO ;1SUB#11#2 <- #32776$#1015 + PLEASE DO ;1SUB#12#1 <- #2048 + DO ;1SUB#12#2 <- #16639$#2 + DO ;1SUB#13#1 <- #1024 + DO ;1SUB#13#2 <- #8192$#127 + PLEASE DO ;1SUB#14#1 <- #512 + DO ;1SUB#14#2 <- #4127$#0 + DO ;1SUB#15#1 <- #256 + DO ;1SUB#15#2 <- #2048$#15 + PLEASE DO ;1SUB#16#1 <- #128 + DO ;1SUB#16#2 <- #1027$#0 + DO ;1SUB#17#1 <- #64 + DO ;1SUB#17#2 <- #512$#1 + PLEASE DO ;1SUB#18#1 <- #32 + DO ;1SUB#18#2 <- #256$#0 + DO ;1SUB#19#1 <- #16 + DO ;1SUB#19#2 <- #32768 + PLEASE DO ;1SUB#20#1 <- #8 + DO ;1SUB#20#2 <- #8192 + DO ;1SUB#21#1 <- #4 + DO ;1SUB#21#2 <- #2048 + PLEASE DO ;1SUB#22#1 <- #2 + DO ;1SUB#22#2 <- #512 + DO ;1SUB#23#1 <- #1 + DO ;1SUB#23#2 <- #128 + PLEASE DO ;1SUB#24#1 <- #0 + DO ;1SUB#24#2 <- #32772$#0 + DO ;1SUB#25#1 <- #0 + DO ;1SUB#25#2 <- #2$#32768 + PLEASE DO ;1SUB#26#1 <- #0 + DO ;1SUB#26#2 <- #16385$#0 + PLEASE RESUME #1 + +(5692) PLEASE DO ;1 <- #32 BY #2 + DO ;1SUB#1#1 <- #42306$#17867 + DO ;1SUB#1#2 <- #2944$#5824 + PLEASE DO ;1SUB#2#1 <- #39940$#43084 + DO ;1SUB#2#2 <- #48096$#35184 + DO ;1SUB#3#1 <- #51944$#40133 + DO ;1SUB#3#2 <- #33328$#62272 + PLEASE DO ;1SUB#4#1 <- #51163$#52407 + DO ;1SUB#4#2 <- #54240$#64048 + DO ;1SUB#5#1 <- #58150$#51158 + DO ;1SUB#5#2 <- #19712$#40320 + PLEASE DO ;1SUB#6#1 <- #57854$#58249 + DO ;1SUB#6#2 <- #51072$#36640 + DO ;1SUB#7#1 <- #61666$#57853 + DO ;1SUB#7#2 <- #16016$#44336 + PLEASE DO ;1SUB#8#1 <- #61567$#61680 + DO ;1SUB#8#2 <- #62928$#36608 + DO ;1SUB#9#1 <- #63548$#61567 + DO ;1SUB#9#2 <- #8672$#56672 + PLEASE DO ;1SUB#10#1 <- #63519$#63550 + DO ;1SUB#10#2 <- #65456$#2144 + DO ;1SUB#11#1 <- #64527$#63519 + DO ;1SUB#11#2 <- #33280$#65008 + PLEASE DO ;1SUB#12#1 <- #64519$#64527 + DO ;1SUB#12#2 <- #65520$#49296 + DO ;1SUB#13#1 <- #65027$#64519 + DO ;1SUB#13#2 <- #61472$#65488 + PLEASE DO ;1SUB#14#1 <- #65025$#65027 + DO ;1SUB#14#2 <- #65520$#63504 + DO ;1SUB#15#1 <- #65280$#65025 + DO ;1SUB#15#2 <- #65024$#65520 + PLEASE DO ;1SUB#16#1 <- #65280$#65280 + DO ;1SUB#16#2 <- #32752$#65296 + DO ;1SUB#17#1 <- #65408$#65280 + DO ;1SUB#17#2 <- #16320$#32752 + PLEASE DO ;1SUB#18#1 <- #65408$#65408 + DO ;1SUB#18#2 <- #8176$#16368 + DO ;1SUB#19#1 <- #65472$#65408 + DO ;1SUB#19#2 <- #4096$#0 + PLEASE DO ;1SUB#20#1 <- #65472$#65472 + DO ;1SUB#20#2 <- #2048$#0 + DO ;1SUB#21#1 <- #65504$#65472 + DO ;1SUB#21#2 <- #1024$#0 + PLEASE DO ;1SUB#22#1 <- #65504$#65504 + DO ;1SUB#22#2 <- #512$#0 + DO ;1SUB#23#1 <- #65520$#65504 + DO ;1SUB#23#2 <- #256$#0 + PLEASE DO ;1SUB#24#1 <- #65520$#65520 + DO ;1SUB#24#2 <- #32768 + DO ;1SUB#25#1 <- #65528$#65520 + DO ;1SUB#25#2 <- #8192 + PLEASE DO ;1SUB#26#1 <- #65528$#65528 + DO ;1SUB#26#2 <- #2048 + DO ;1SUB#27#1 <- #65532$#65528 + DO ;1SUB#27#2 <- #512 + PLEASE DO ;1SUB#28#1 <- #65532$#65532 + DO ;1SUB#28#2 <- #0 + DO ;1SUB#29#1 <- #65534$#65532 + DO ;1SUB#29#2 <- #0 + PLEASE DO ;1SUB#30#1 <- #65534$#65534 + DO ;1SUB#30#2 <- #0 + DO ;1SUB#31#1 <- #65535$#65534 + DO ;1SUB#31#2 <- #0 + PLEASE DO ;1SUB#32#1 <- #65535$#65535 + DO ;1SUB#32#2 <- #0 + PLEASE RESUME #1 + +(5693) PLEASE DO ;1 <- #31 BY #2 + DO ;1SUB#1#1 <- #20958$#18912 + DO ;1SUB#1#2 <- #41802$#3139 + PLEASE DO ;1SUB#2#1 <- #11856$#29363 + DO ;1SUB#2#2 <- #20278$#38329 + DO ;1SUB#3#1 <- #16126$#13134 + DO ;1SUB#3#2 <- #36988$#26789 + PLEASE DO ;1SUB#4#1 <- #7293$#16290 + DO ;1SUB#4#2 <- #62389$#4572 + DO ;1SUB#5#1 <- #8181$#7710 + DO ;1SUB#5#2 <- #52198$#46965 + PLEASE DO ;1SUB#6#1 <- #3971$#8189 + DO ;1SUB#6#2 <- #63827$#18313 + DO ;1SUB#7#1 <- #4095$#4032 + DO ;1SUB#7#2 <- #43913$#64878 + PLEASE DO ;1SUB#8#1 <- #2032$#4095 + DO ;1SUB#8#2 <- #8178$#60047 + DO ;1SUB#9#1 <- #2047$#2040 + DO ;1SUB#9#2 <- #64855$#2042 + PLEASE DO ;1SUB#10#1 <- #1022$#2047 + DO ;1SUB#10#2 <- #254$#65366 + DO ;1SUB#11#1 <- #1023$#1023 + DO ;1SUB#11#2 <- #65515$#62 + PLEASE DO ;1SUB#12#1 <- #511$#1023 + DO ;1SUB#12#2 <- #49159$#65531 + DO ;1SUB#13#1 <- #511$#511 + DO ;1SUB#13#2 <- #65535$#57345 + PLEASE DO ;1SUB#14#1 <- #255$#511 + DO ;1SUB#14#2 <- #63488$#65535 + DO ;1SUB#15#1 <- #65535 + DO ;1SUB#15#2 <- #65535$#64513 + PLEASE DO ;1SUB#16#1 <- #32767 + DO ;1SUB#16#2 <- #65280$#65535 + DO ;1SUB#17#1 <- #16383 + DO ;1SUB#17#2 <- #65535$#65409 + PLEASE DO ;1SUB#18#1 <- #8191 + DO ;1SUB#18#2 <- #65504$#65535 + DO ;1SUB#19#1 <- #4095 + DO ;1SUB#19#2 <- #65535$#65521 + PLEASE DO ;1SUB#20#1 <- #2047 + DO ;1SUB#20#2 <- #65532$#65535 + DO ;1SUB#21#1 <- #1023 + DO ;1SUB#21#2 <- #65535$#65535 + PLEASE DO ;1SUB#22#1 <- #512 + DO ;1SUB#22#2 <- #0 + DO ;1SUB#23#1 <- #256 + DO ;1SUB#23#2 <- #0 + PLEASE DO ;1SUB#24#1 <- #128 + DO ;1SUB#24#2 <- #0 + DO ;1SUB#25#1 <- #64 + DO ;1SUB#25#2 <- #0 + PLEASE DO ;1SUB#26#1 <- #32 + DO ;1SUB#26#2 <- #0 + DO ;1SUB#27#1 <- #16 + DO ;1SUB#27#2 <- #0 + PLEASE DO ;1SUB#28#1 <- #8 + DO ;1SUB#28#2 <- #0 + DO ;1SUB#29#1 <- #4 + DO ;1SUB#29#2 <- #0 + PLEASE DO ;1SUB#30#1 <- #2 + DO ;1SUB#30#2 <- #0 + DO ;1SUB#31#1 <- #1 + DO ;1SUB#31#2 <- #0 + PLEASE RESUME #1 diff --git a/pit/lib/lib2.doc b/pit/lib/lib2.doc new file mode 100644 index 0000000..39418b6 --- /dev/null +++ b/pit/lib/lib2.doc @@ -0,0 +1,35 @@ + +lib2.i contains general-purpose library routines that are not included +in the standard library. + +The first section, with entry at lines (2000), (2010) and (2020), +was written for the Life program. Line (2000) is the entry point +for a decrement routine setting .1 <- .1 minus #1. This is very +similar to the increment routine (1020) in the system library, +which I also use. Line (2010) is the decrement and branch on zero +operation. It decrements .1, then if .1 is not zero returns to the +calling point, but if .1 is zero pops an additional entry off the +RESUME stack and returns to that point instead. Line (2020) is an +alternative entry point to the (1020) routine which performs an add +bit operation. It sets .1 <- .1 plus .2, where .2 is already known +to be either #0 or #1. + +For the pi and primes programs I added the (2030) routine, which +performs a 16-bit division with remainder. It is faster than the +(1040) routine for two reasons: First, it is a true 16-bit version, +whereas the (1040) routine just shifts over its operands and then +calls the 32-bit division routine (1550). Second, the (1550) routine +generates a remainder as part of the computation, but then simply +throws it away. I needed the remainder, so I have my (2030) routine +return it in .4 and the quotient in .3. In other respects this is +just a 16-bit translation of the (1550) routine. + +(2040) and (2049) are entry points to an exponentiation routine that +raises .1 to the .2 power and returns the answer in :1. If entered +through (2040) the routine dies with an error on overflow. If entered +through (2049) then .4 is set to #2 if there is an overflow, otherwise +.4 is set to #1. There is a more detailed description of how this +routine works on the web page. + + Louis Howell + May 27, 1996 diff --git a/pit/lib/lib2.i b/pit/lib/lib2.i index 7676c44..eda0691 100644 --- a/pit/lib/lib2.i +++ b/pit/lib/lib2.i @@ -2,7 +2,7 @@ (2000) PLEASE STASH .2 DO .2 <- #1 DO (2001) NEXT -(2001) DO FORGET #1 +(2001) PLEASE FORGET #1 DO .1 <- '?.1$.2'~'#0$#65535' DO (2002) NEXT DO .2 <- !2$#0'~'#32767$#1' @@ -28,7 +28,7 @@ PLEASE DO .4 <- !4$#0'~'#32767$#1' DO (2033) NEXT (2032) DO (1001) NEXT -(2036) DO FORGET #1 +(2036) PLEASE FORGET #1 DO .5 <- '?.1$.2'~'#0$#65535' DO .5 <- '?"'&"!2~.5'~'"?'?.5~.5'$#32768"~"#0$#65535"'"$ ".5~.5"'~#1"$#2'~#3 @@ -49,3 +49,49 @@ PLEASE DO .4 <- .1 DO RETRIEVE .1 + .5 PLEASE RESUME #2 +(2040) PLEASE STASH .4 + DO ABSTAIN FROM (2047) +(2049) DO STASH .2 + .5 + :2 + :3 + :4 + :5 + :6 + PLEASE DO .4 <- #0 + DO :5 <- .1 + DO :6 <- #1 + DO (2044) NEXT + DO .4 <- '?.4$#1'~#3 +(2047) DO (2048) NEXT + DO .5 <- .4 + DO (2046) NEXT + DO (1999) NEXT +(2046) DO (1001) NEXT + PLEASE REINSTATE (2047) + PLEASE RETRIEVE .4 +(2048) DO :1 <- :6 + DO RETRIEVE .2 + .5 + :2 + :3 + :4 + :5 + :6 + PLEASE RESUME #2 +(2044) DO (2045) NEXT +(2045) PLEASE FORGET #1 + DO .5 <- "?!2~#1'$#1"~#3 + DO (2041) NEXT + DO :3 <- :6~"#65535$#65534" + DO .5 <- '?"':3~:3'~#1"$#1'~#3 + DO (2042) NEXT + PLEASE DO :1 <- :6 + PLEASE DO :2 <- :5 + DO (1549) NEXT + DO :6 <- :3 + DO .4 <- 'V.4$":4~#2"'~#1 + DO (2043) NEXT +(2042) DO (1001) NEXT + PLEASE FORGET #1 + DO :6 <- :5 + DO (2043) NEXT +(2041) DO (1001) NEXT +(2043) PLEASE FORGET #1 + DO .2 <- .2~#65534 + DO .5 <- '?"!2~.2'~#1"$#2'~#3 + DO (1001) NEXT + PLEASE DO :1 <- :5 + PLEASE DO :2 <- :5 + DO (1549) NEXT + DO :5 <- :3 + DO .4 <- 'V.4$":4~#2"'~#1 + DO (2045) NEXT diff --git a/pit/lib/numio.doc b/pit/lib/numio.doc index 9b76790..c509534 100644 --- a/pit/lib/numio.doc +++ b/pit/lib/numio.doc @@ -2,24 +2,68 @@ Summary of routines in numio.i: (3000) .1 <- character from input (3001) Prints .2 as a character +(3010) ,1 <- a string of input from the user, no longer than .1, and + excluding the terminating newline. + .2 <- the real length of the user input. + .3 <- #1 if .2 <= .1 (i.e., no characters were lost). + Otherwise, .3 <- #2. +(3020) ,1 <- a string of input from the user, no longer than .1, + translated (where possible) into indices into ,2 + .3 <- the real length of the user input. + .4 <- #1 if .3 <= .1 and all characters in the input are + listed in ,2. Otherwise, .4 <- #2. (3080) .1 <- a 16-bit number from the user (3089) .1 <- a 16-bit number from the user, with an error message if non-digits are encountered (3090) Displays the value in .1 (3099) Displays the value in .1 and prints a newline -(3080) :1 <- a 32-bit number from the user -(3089) :1 <- a 32-bit number from the user, with an error message if +(3180) :1 <- a 32-bit number from the user +(3189) :1 <- a 32-bit number from the user, with an error message if non-digits are encountered -(3090) Displays the value in :1 -(3099) Displays the value in :1 and prints a newline +(3190) Displays the value in :1 +(3199) Displays the value in :1 and prints a newline (3990) Initializes internal arrays. -The file numio.i contains routines for doing "wimpmode"-style I/O - or -in other words, the C-INTERCAL equivalent of atoi and itoa. (3080) and +numio.i reserves the use of two arrays - ,3000 and ,3001 - for input +and output respectively. Each array has one dimension of one element, +and they are used to provide a getchar routine, at (3000), and a +putchar routine, (3001). Note that (3001) expects that the character +values have already been bit-reversed. + +The arrays are initialized by routine (3990); this should be called +before using any other routines in this library. + +Routines (3010) and (3020) provide line input capabilities. The +routines write in characters until they see a newline (or +end-of-file), and store them in ,1. They are called with .1 being the +number of characters to save; any input after that is thrown +away. (Already they're better than C's gets()!) + +(3010) returns the actual number of characters that were input in .2, +and .3 is set to #2 if characters were lost (i.e., if .2 is longer +than .1). I decided to add .3, even though the caller could check for +this themselves, as inequal comparisons are a bit painful in INTERCAL. +Or, to be accurate, they're more painful than equal comparisons. Note +also that if .1 is #0, the routine becomes a press-Enter-to-continue +type of function, and ,1 need not actually be defined. + +(3020) is a filtering, or translating, input routine. When called, the +array ,2 should contain a set of "approved" characters that are +expected to be in the input, and .2 should contain the number of +characters in ,2. As input is retrieved, the routine tries to look up +each character in ,2. If the character is found, the routine stores in +,1 the index of the character instead. (Otherwise the actual character +number is stored, as with (3010).) Upon return, .3 has the number of +characters that were input, and .4 is set to #2 if characters were +lost OR if any characters in the input were not in the set of approved +characters. + +The remaining routines are for doing "wimpmode"-style I/O - or in +other words, the C-INTERCAL equivalent of atoi and itoa. (3080) and (3090) translate the ASCII input as a number (yes, a number as in [0-9]*), and (3090) and (3190) do the same for displaying numbers in ASCII. (By the way, the routines can also be made to support EBCDIC: -simply replace #3 with #15 on lines 41, 81, and 107.) +simply replace #3 with #15 on lines 119, 159, and 185.) Each routine also has a "niner" variation. For itoa, (3099) and (3190) print a newline at the end of the number. In the case of atoi, (3089) @@ -29,42 +73,26 @@ input line. If there are, a typically snide INTERCAL error message is displayed. (The regular versions work like C's atoi in that they return as soon as they see any non-digit.) -There's not too much to note about these routines. The atoi versions +There's not too much to note about these routines. The atoi routines use the shift-and-add trick to avoid multiplying by 10, so they should be pretty efficient (snort). itoa has no such shortcuts, and the -routines use the modified division routine which also returns the +routines use modified division routines which also returns the remainder. The 16-bit version is at (2030), and is the familiar one -created by Louis Howell, copied from syslib2.i. The 32-bit version is -at (2530), and is just a copy of the standard library routine without -the lines that throw away the remainder at the end. - -The library reserves the use of two arrays - ,3000 and ,3001 - for -input and output respectively. Each array has one dimension of one -element, and they are used to provide a getchar and putchar: routines -(3000) and (3001). - -The arrays are initialized by routine (3990); this should be called -before using any other routines in this file. +created by Louis Howell, copied from lib2.i. The 32-bit version is at +(2530), and is just a copy of the standard library routine without the +lines that throw away the remainder at the end. Note also that for these routines to work properly, they must be used more or less exclusively in regards to other array I/O. Otherwise, the -getchar and putchar subroutines will get out of synch with the +getchar and putchar subroutines will get out of sync with the Turing-text character loop. If you do want to do other I/O while using -these routines, you can use (3000) and (3001) as a getchar and putchar -(note that the latter expects that the character values have already -been reversed). Or, you can simply re-initialize the ,3000 and/or -,3001 values after you are done, by storing in them the ASCII value of -the last character that you wrote in and/or read out. For example, -if you have displayed some strings and the last thing to be printed +these routines, you can use (3000) and (3001) as a getchar and +putchar. Or, you can simply re-initialize the ,3000 and/or ,3001 +values after you are done, by storing in them the bit-reversed ASCII +value of the last character that you wrote in and/or read out. For +example, if you READ OUT some strings and the last thing to be printed was a newline, then: DO ,3001SUB#1 <- #80 -would allow you to safely call the itoa routines, since 80 is the -bit-reversal of 10. - - -It is my earnest hope that C-INTERCAL programmers everywhere will -flock to these handy routines, and C-INTERCAL users will thus no -longer need to fear that they might succumb to the foul and awful -temptation to use the dastardly +wimpmode option. +would then allow you to safely call the itoa routines. diff --git a/pit/lib/numio.i b/pit/lib/numio.i index 35aaf88..e75f19d 100644 --- a/pit/lib/numio.i +++ b/pit/lib/numio.i @@ -1,14 +1,18 @@ PLEASE USE THE AUTHORIZED CHANNELS -(3000) DO STASH .2 + .3 - DO .1 <- ,3000SUB#1 - PLEASE WRITE IN ,3000 +(3000) DO STASH .2 + .3 + .5 DO .2 <- ,3000SUB#1 + PLEASE WRITE IN ,3000 + DO .1 <- ,3000SUB#1 + DO .5 <- '?".1~#256"$#2'~#3 + DO (3008) NEXT DO (1000) NEXT DO .1 <- .3~#255 DO ,3000SUB#1 <- .1 - DO RETRIEVE .2 + .3 - PLEASE RESUME #1 + DO (3009) NEXT +(3008) DO (1001) NEXT +(3009) DO RETRIEVE .2 + .3 + .5 + PLEASE RESUME #2 (3001) DO STASH .1 + .3 DO .1 <- ,3001SUB#1 @@ -20,6 +24,80 @@ DO RETRIEVE .1 + .3 PLEASE RESUME #1 +(3010) PLEASE STASH .1 + .4 + .5 + PLEASE DO (1020) NEXT + DO .2 <- #0 + DO .3 <- #2 + DO .4 <- .1 + DO (3012) NEXT +(3011) DO (1001) NEXT +(3012) PLEASE FORGET #1 + DO (3000) NEXT + DO .5 <- '?"?.1~#256"$#2'~#3 + DO (3013) NEXT + DO .5 <- '?"'#65535~"'?.1$#10'~#21845"'~#1"$#1'~#3 + DO (3013) NEXT + DO .5 <- .1 + DO .1 <- .2 + PLEASE DO (1020) NEXT + DO .2 <- .1 + DO .1 <- .5 + DO .5 <- .3 + DO (3011) NEXT + DO .5 <- '?"'#65535~"'?.2$.4'~'#0$#65535'"'~#1"$#1'~#3 + DO .3 <- .5 + DO (3011) NEXT + PLEASE DO ,1SUB.2 <- .1 + DO (3012) NEXT +(3013) DO (1001) NEXT + PLEASE RETRIEVE .1 + .4 + .5 + PLEASE DO .3 <- '?.3$#3'~#5 + PLEASE RESUME #2 + +(3020) PLEASE STASH .1 + .5 + .6 + .7 + DO (1020) NEXT + DO .3 <- #0 + DO .4 <- #6 + DO .6 <- .1 + DO (3022) NEXT +(3021) DO (1001) NEXT +(3022) PLEASE FORGET #1 + DO (3000) NEXT + DO .5 <- '?"?.1~#256"$#2'~#3 + DO (3023) NEXT + DO .5 <- '?"'#65535~"'?.1$#10'~#21845"'~#1"$#1'~#3 + DO (3023) NEXT + DO .7 <- .1 + DO .1 <- .3 + PLEASE DO (1020) NEXT + DO .3 <- .1 + DO .5 <- .4~#3 + DO (3021) NEXT + DO .5 <- '?"'#65535~"'?.3$.6'~'#0$#65535'"'~#1"$#1'~#3 + DO .4 <- !4$.5'~#37 + DO (3021) NEXT +(3027) DO .1 <- #0 + PLEASE COME FROM (3024) + PLEASE DO (1020) NEXT + DO .5 <- '?"'#65535~"'?.7$",2SUB.1"'~#21845"'~#1"$#1'~#3 + DO (3025) NEXT + PLEASE COME FROM (3027) + DO .5 <- '?"'#65535~"'?.1$.2'~'#0$#65535'"'~#1"$#1'~#3 +(3024) DO (3026) NEXT +(3026) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE DO ,1SUB.3 <- .7 + DO .4 <- .4~#3 + DO (3022) NEXT +(3025) DO (1001) NEXT + PLEASE FORGET #1 + PLEASE DO ,1SUB.3 <- .1 + DO (3022) NEXT +(3023) DO (1001) NEXT + PLEASE RETRIEVE .1 + .5 + .6 + .7 + DO .4 <- '?#2$.&4'~#6 + PLEASE RESUME #2 + (3089) PLEASE ABSTAIN FROM (3087) (3080) PLEASE STASH .2 + .3 + .4 DO .3 <- #0 @@ -29,7 +107,7 @@ DO .4 <- '?.1$#10'~'#0$#65535' DO .4 <- .4~.4 DO (3085) NEXT -(3998) DOES "ENTER A NUMBER" MEAN SOMETHING DIFFERENT WHERE YOU COME FROM? +(3998) DOES "ENTER A NUMBER" MEAN SOMETHING ELSE WHERE YOU COME FROM? (3085) DO (3086) NEXT (3088) PLEASE FORGET #1 DO .1 <- .3 @@ -121,7 +199,7 @@ (3182) DO (1500) NEXT (3190) PLEASE ABSTAIN FROM (3197) -(3199) PLEASE STASH :1 + :2 + :3 + .2 + .4 +(3199) PLEASE STASH :1 + :2 + :3 + :4 + .2 + .4 DO :2 <- #10 DO .2 <- #256 PLEASE STASH .2 @@ -130,7 +208,7 @@ DO .2 <- #80 (3197) DO (3001) NEXT PLEASE REINSTATE (3197) - PLEASE RETRIEVE :1 + :2 + :3 + .2 + .4 + PLEASE RETRIEVE :1 + :2 + :3 + :4 + .2 + .4 PLEASE RESUME #1 (3198) PLEASE RESUME '?"':1~:1'~#1"$#2'~#3 (3191) DO COME FROM (3192) @@ -140,9 +218,9 @@ DO :1 <- :3 (3192) DO (3198) NEXT -(3990) DO ,3000 <- #1 +(3990) PLEASE DO ,3000 <- #1 DO ,3000SUB#1 <- #0 - DO ,3001 <- #1 + PLEASE DO ,3001 <- #1 DO ,3001SUB#1 <- #0 PLEASE RESUME #1 diff --git a/pit/lib/syslib.3i b/pit/lib/syslib.3i new file mode 100644 index 0000000..fd1ea3c --- /dev/null +++ b/pit/lib/syslib.3i @@ -0,0 +1,323 @@ + PLEASE KNOCK THREE TIMES BEFORE ENTERING + + (1000) PLEASE IGNORE .4 + PLEASE ABSTAIN FROM (1005) + (1009) DO STASH .1 + .2 + .5 + .6 + DO .4 <- #1 + DO (1004) NEXT + (1004) PLEASE FORGET #1 + DO .3 <- '^.1$.2'~'#0$#29524' + DO .6 <- '?"'V"'&.1$.2'~'#0$#29524'"$#29524' + ~'#0$#29524'"$#29524'~'#0$#29524' + PLEASE DO .5 <- 'V".6~#39366"$#1'~#1 + DO (1002) NEXT + DO .4 <- #2 + (1005) DO (1006) NEXT + (1999) DOUBLE OR SINGLE PRECISION OVERFLOW + (1002) DO (1001) NEXT + (1006) PLEASE FORGET #1 + DO .5 <- 'V"!6~.6'~#2"$#1'~#1 + DO (1003) NEXT + DO .1 <- .3 + DO .2 <- !6$#0'~'#9841$#1' + DO (1004) NEXT + (1003) DO (1001) NEXT + DO REINSTATE (1005) + (1007) PLEASE RETRIEVE .1 + .2 + .5 + .6 + DO REMEMBER .4 + PLEASE RESUME #2 + (1001) DO RESUME .5 + (1010) DO STASH .1 + .2 + .4 + DO .4 <- .1 + DO .1 <- '?#59048$.2'~'#0$#29524' + DO (1020) NEXT + PLEASE DO .2 <- .4 + PLEASE DO (1009) NEXT + DO RETRIEVE .1 + .2 + .4 + PLEASE RESUME #1 + (1020) DO STASH .2 + .3 + DO .2 <- #1 + PLEASE DO (1021) NEXT + (1021) DO FORGET #1 + DO .3 <- 'V"!1~.2'$#1"'~#1 + PLEASE DO .1 <- '^.1$.2'~'#0$#29524' + DO (1022) NEXT + DO .2 <- !2$#0'~'#9841$#1' + DO (1021) NEXT + (1023) PLEASE RESUME .3 + (1022) DO (1023) NEXT + PLEASE RETRIEVE .2 + .3 + PLEASE RESUME #2 + (1030) DO ABSTAIN FROM (1033) + PLEASE ABSTAIN FROM (1032) + (1039) DO STASH :1 + .5 + DO (1530) NEXT + DO .3 <- :1~#29524 + PLEASE DO .5 <- :1~'#29403$#29403' + DO .5 <- 'V"!5~.5'~#2"$#1'~#1 + DO (1031) NEXT + (1032) DO (1033) NEXT + DO (1999) NEXT + (1031) DO (1001) NEXT + (1033) DO .4 <- .5 + DO REINSTATE (1032) + PLEASE REINSTATE (1033) + DO RETRIEVE :1 + .5 + PLEASE RESUME #2 + (1040) PLEASE STASH .1 + .2 + .2 + :1 + :2 + :3 + DO .2 <- #0 + DO (1520) NEXT + DO STASH :1 + PLEASE RETRIEVE .2 + DO .1 <- .2 + DO .2 <- #0 + PLEASE DO (1520) NEXT + DO :2 <- :1 + DO RETRIEVE .1 + .2 + :1 + DO (1550) NEXT + PLEASE DO .3 <- :3 + DO RETRIEVE :1 + :2 + :3 + DO RESUME #1 + (1050) PLEASE STASH :2 + :3 + .5 + DO :2 <- .1 + PLEASE DO (1550) NEXT + DO .5 <- :3~'#29403$#29403' + DO .5 <- 'V"!5~.5'~#2"$#1'~#1 + DO (1051) NEXT + DO (1999) NEXT + (1051) DO (1001) NEXT + DO .2 <- :3 + PLEASE RETRIEVE :2 + :3 + .5 + DO RESUME #2 + (1500) PLEASE ABSTAIN FROM (1502) + PLEASE ABSTAIN FROM (1506) + (1509) PLEASE STASH :1 + .1 + .2 + .3 + .4 + .5 + .6 + DO .1 <- :1~#29524 + PLEASE DO .2 <- :2~#29524 + DO (1009) NEXT + DO .5 <- .3 + PLEASE DO .6 <- .4 + DO .1 <- :1~'#29403$#29403' + DO .2 <- :2~'#29403$#29403' + DO (1009) NEXT + DO .1 <- .3 + PLEASE DO (1503) NEXT + DO .6 <- .4 + DO .2 <- #1 + DO (1009) NEXT + DO .1 <- .3 + DO (1501) NEXT + (1504) PLEASE RESUME .6 + (1503) DO (1504) NEXT + (1501) DO .2 <- .5 + DO .5 <- '&.6$.4' + DO (1505) NEXT + (1506) DO (1502) NEXT + PLEASE DO (1999) NEXT + (1505) DO (1001) NEXT + (1502) DO :4 <- .5 + DO (1520) NEXT + DO :3 <- :1 + PLEASE RETRIEVE :1 + .1 + .2 + .3 + .4 + .5 + .6 + DO REINSTATE (1502) + DO REINSTATE (1506) + PLEASE RESUME #3 + (1510) DO STASH :1 + :2 + :4 + DO :1 <- "'?#59048$":2~'#29524$#0'"'~'#0$#29524'" + $"'?#59048$":2~'#0$#29524'"'~'#0$#29524'" + DO :2 <- #1 + DO (1509) NEXT + PLEASE RETRIEVE :1 + DO :2 <- :3 + PLEASE DO (1509) NEXT + DO RETRIEVE :2 + :4 + PLEASE RESUME #1 + (1520) PLEASE STASH .3 + .4 + DO .3 <- .1~#22143 + DO (1525) NEXT + PLEASE DO .4 <- 'V.3$".2~#22143"'~'#0$#29524' + DO .3 <- .1~#7381 + PLEASE DO (1525) NEXT + DO :1 <- .4$"'V.3$".2~#7381"'~'#0$#29524'" + PLEASE RETRIEVE .3 + .4 + DO RESUME #1 + (1525) DO .3 <- '"'"!3$#0'~'#9841$#1'"$#0'~'#3280$#4'" + $#0'~'#3280$#4' + PLEASE RESUME #1 + (1530) DO STASH :2 + :3 + .3 + .5 + DO :1 <- #0 + DO :2 <- .2 + DO .3 <- #1 + DO (1535) NEXT + (1535) PLEASE FORGET #1 + DO .5 <- '@"'^".1~.3"$#7'~#4"$#2'~#10 + DO (1534) NEXT + DO (1500) NEXT + DO :1 <- :3 + DO (1536) NEXT + (1534) DO (1531) NEXT + (1536) DO (1500) NEXT + DO :1 <- :3 + PLEASE DO (1533) NEXT + (1531) PLEASE DO (1001) NEXT + (1533) DO FORGET #2 + DO .3 <- !3$#0'~'#9841$#1' + DO :2 <- ":2~'#0$#29524'"$"'":2~'#9841$#0'"$#0' + ~'#9841$#1'" + PLEASE DO .5 <- 'V"!3~.3'~#2"$#1'~#1 + DO (1532) NEXT + DO (1535) NEXT + (1532) DO (1001) NEXT + PLEASE RETRIEVE :2 + :3 + .3 + .5 + DO RESUME #2 + (1540) PLEASE ABSTAIN FROM (1541) + DO ABSTAIN FROM (1542) + (1549) PLEASE STASH :1 + :2 + :4 + :5 + .1 + .2 + .5 + DO .1 <- :1~#29524 + PLEASE DO .2 <- :2~'#29403$#29403' + DO .5 <- :1~'#29403$#29403' + DO (1530) NEXT + DO :3 <- :1 + DO .2 <- :2~#29524 + PLEASE DO (1530) NEXT + DO :5 <- :1 + DO .1 <- .5 + DO (1530) NEXT + DO :4 <- :1 + PLEASE DO :1 <- ":3~'#29403$#29403'"$":4~'#29403 + $#29403'" + DO .5 <- ':1~:1'~#2 + DO .2 <- :2~'#29403$#29403' + DO (1530) NEXT + PLEASE DO .5 <- '"':1~:1'~#2"$.5'~#4 + DO .1 <- :3~#29524 + DO .2 <- #0 + DO (1520) NEXT + PLEASE DO :2 <- :1 + PLEASE DO .1 <- :4~#29524 + DO (1520) NEXT + DO (1509) NEXT + DO .5 <- !5$":4~#1"'~#31 + DO :1 <- :3 + DO :2 <- :5 + DO (1509) NEXT + PLEASE DO .5 <- !5$":4~#1"'~#274 + DO .5 <- !5~.5'~#1 + PLEASE RETRIEVE :4 + (1541) DO :4 <- .5 + DO (1543) NEXT + (1542) DO (1544) NEXT + PLEASE DO (1999) NEXT + (1543) DO (1001) NEXT + (1544) DO REINSTATE (1541) + PLEASE REINSTATE (1542) + PLEASE RETRIEVE :1 + :2 + :5 + .1 + .2 + .5 + DO RESUME #2 + (1550) DO STASH :1 + :4 + :5 + :6 + .5 + DO :3 <- #0 + DO .5 <- 'V"':2~:2'~#2"$#1'~#1 + PLEASE DO (1551) NEXT + DO :4 <- #1 + PLEASE DO (1553) NEXT + (1553) DO FORGET #1 + DO .5 <- '?"':2~"#39366$#0"'"$#1'~#1 + DO (1552) NEXT + DO :2 <- ":2~'#0$#29524'"$"'":2~'#9841$#0'"$#0' + ~'#9841$#1'" + PLEASE DO :4 <- ":4~'#0$#29524'"$"'":4~'#9841 + $#0'"$#0'~'#9841$#1'" + DO (1553) NEXT + (1552) DO (1001) NEXT + (1556) PLEASE FORGET #1 + DO :6 <- "'&":2~'#29524$#0'"$"'?#59048$":1 + ~'#29524$#0'"'~'#0$#29524'"'~'#0$#29524'"$ + "'&":2~'#0$#29524'"$"'?#59048$":1~'#0$ + #29524'"'~'#0$#29524'"'~'#0$#29524'" + DO :5 <- "'?":1~'#29524$#0'"$":2~'#29524$#0'"' + ~'#0$#59048'"$"'?":1~'#0$#29524'"$":2~'#0$ + #29524'"'~'#0$#59048'" + DO .5 <- "?'"':6~:5'~'"'"'&"':5~:5'~'#29524$#0'"$ + #19683'~'#0$#29524'"$"'?:5~:5'~'#9841$#0'"' + ~'#19683$#9841'"$"'?:5~:5'~'#0$#29524'"'" + ~#1'$#1"~#1 + DO (1554) NEXT + DO :5 <- :3 + DO (1510) NEXT + PLEASE DO :1 <- :3 + DO :6 <- "'&":2~'#29524$#0'"$"'?#59048$":1 + ~'#29524$#0'"'~'#0$#29524'"'~'#0$#29524'"$ + "'&":2~'#0$#29524'"$"'?#59048$":1~'#0$ + #29524'"'~'#0$#29524'"'~'#0$#29524'" + DO :3 <- "'?":1~'#29524$#0'"$":2~'#29524$#0'"' + ~'#0$#59048'"$"'?":1~'#0$#29524'"$":2~'#0$ + #29524'"'~'#0$#59048'" + DO .5 <- "?'"':6~:3'~'"'"'&"':3~:3'~'#29524$#0'"$ + #19683'~'#0$#29524'"$"'?:3~:3'~'#9841$#0'"' + ~'#19683$#9841'"$"'?:3~:3'~'#0$#29524'"'" + ~#1'$#1"~#1 + DO (1557) NEXT + DO (1510) NEXT + PLEASE DO :1 <- :3 + DO :3 <- "'V":4~'#59048$#0'"$":5~'#29524$#0'"' + ~'#0$#29524'"$"'V":4~'#0$#59048'"$":5~'#0$ + #29524'"'~'#0$#29524'" + PLEASE DO (1555) NEXT + (1557) PLEASE DO (1001) NEXT + PLEASE FORGET #1 + DO :3 <- "'V":4~'#29524$#0'"$":5~'#29524$#0'"' + ~'#0$#29524'"$"'V":4~'#0$#29524'"$":5~'#0$ + #29524'"'~'#0$#29524'" + PLEASE DO (1555) NEXT + (1554) PLEASE DO (1001) NEXT + (1555) PLEASE FORGET #1 + DO .5 <- "?':4~#2'$#1"~#1 + DO (1551) NEXT + DO :2 <- :2~'#29524$#29523' + DO :4 <- :4~'#29524$#29523' + PLEASE DO (1556) NEXT + (1551) DO (1001) NEXT + PLEASE RETRIEVE :1 + :4 + :5 + :6 + .5 + PLEASE RESUME #2 + (1900) DO STASH .2 + .5 + DO .1 <- #0 + DO .2 <- #1 + PLEASE DO (1901) NEXT + (1901) DO FORGET #1 + DO %50 (1904) NEXT + DO %50 (1901) NEXT + PLEASE DO (1903) NEXT + (1904) DO .1 <- '^.1$.2'~'#0$#29524' + DO %50 .1 <- '^.1$.2'~'#0$#29524' + (1903) PLEASE FORGET #1 + DO .2 <- !2$#0'~'#9841$#1' + PLEASE DO .5 <- 'V"!2~.2'~#2"$#1'~#1 + DO (1902) NEXT + DO (1901) NEXT + (1902) DO (1001) NEXT + DO RETRIEVE .2 + .5 + PLEASE RESUME #2 + (1910) PLEASE STASH .1 + .3 + .5 + :1 + :2 + :3 + DO .3 <- #59037 + DO :1 <- #6 + DO (1911) NEXT + PLEASE NOTE THAT YOU CAN'T GET THREE FROM HERE + (1912) DO (1001) NEXT + (1911) DO FORGET #1 + PLEASE DO (1900) NEXT + DO :2 <- .1 + DO (1500) NEXT + PLEASE DO :1 <- :3 + DO .1 <- .3 + DO (1020) NEXT + PLEASE DO .3 <- .1 + DO .5 <- '?"!3~.3'~#2"$#1'~#1 + DO (1912) NEXT + DO .1 <- #12 + PLEASE DO (1050) NEXT + DO RETRIEVE .1 + DO (1530) NEXT + DO :2 <- #29524 + DO (1500) NEXT + PLEASE DO .2 <- :3~'#29403$#29403' + PLEASE RETRIEVE .3 + .5 + :1 + :2 + :3 + DO RESUME #1 diff --git a/pit/lib/syslib.4i b/pit/lib/syslib.4i new file mode 100644 index 0000000..d1c1084 --- /dev/null +++ b/pit/lib/syslib.4i @@ -0,0 +1,354 @@ + PLEASE KNOCK TWICE TWO TIMES BEFORE ENTERING + + (1000) PLEASE IGNORE .4 + PLEASE ABSTAIN FROM (1005) + (1009) DO STASH .1 + .2 + .5 + .6 + DO .4 <- #1 + DO (1004) NEXT + (1004) PLEASE FORGET #1 + DO .3 <- '^.1$.2'~'#0$#21845' + DO .6 <- '?"'V"'&.1$.2'~'#0$#21845'"$"'^"'@.1$ + .2'~'#0$#21845'"$#21845'~'#0$#43690'"' + ~'#0$#21845'"$#43690'~'#0$#21845' + PLEASE DO .5 <- '?".6~#49152"$#4'~#4 + DO (1002) NEXT + DO .4 <- #2 + (1005) DO (1006) NEXT + (1999) DOUBLE OR SINGLE PRECISION OVERFLOW + (1002) DO (1001) NEXT + (1006) PLEASE FORGET #1 + DO .5 <- '?"!6~.6'~#3"$#4'~#4 + DO (1003) NEXT + DO .1 <- .3 + DO .2 <- !6$#0'~'#5461$#1' + DO (1004) NEXT + (1003) DO (1001) NEXT + DO REINSTATE (1005) + (1007) PLEASE RETRIEVE .1 + .2 + .5 + .6 + DO REMEMBER .4 + PLEASE RESUME #2 + (1001) DO RESUME .5 + (1010) DO STASH .1 + .2 + .4 + DO .4 <- .1 + DO .1 <- '?#65535$.2'~'#0$#21845' + DO (1020) NEXT + PLEASE DO .2 <- .4 + PLEASE DO (1009) NEXT + DO RETRIEVE .1 + .2 + .4 + PLEASE RESUME #1 + (1020) DO STASH .2 + .3 + DO .2 <- #1 + PLEASE DO (1021) NEXT + (1021) DO FORGET #1 + DO .3 <- '?"'V".1~.2"$#2'~#1"$#1'~#1 + PLEASE DO .1 <- '^.1$.2'~'#0$#21845' + DO (1022) NEXT + DO .2 <- !2$#0'~'#5461$#1' + DO (1021) NEXT + (1023) PLEASE RESUME .3 + (1022) DO (1023) NEXT + PLEASE RETRIEVE .2 + .3 + PLEASE RESUME #2 + (1030) DO ABSTAIN FROM (1033) + PLEASE ABSTAIN FROM (1032) + (1039) DO STASH :1 + .5 + DO (1530) NEXT + DO .3 <- :1~#21845 + PLEASE DO .5 <- :1~'#21760$#21760' + DO .5 <- '?"!5~.5'~#3"$#4'~#4 + DO (1031) NEXT + (1032) DO (1033) NEXT + DO (1999) NEXT + (1031) DO (1001) NEXT + (1033) DO .4 <- .5 + DO REINSTATE (1032) + PLEASE REINSTATE (1033) + DO RETRIEVE :1 + .5 + PLEASE RESUME #2 + (1040) PLEASE STASH .1 + .2 + .2 + :1 + :2 + :3 + DO .2 <- #0 + DO (1520) NEXT + DO STASH :1 + PLEASE RETRIEVE .2 + DO .1 <- .2 + DO .2 <- #0 + PLEASE DO (1520) NEXT + DO :2 <- :1 + DO RETRIEVE .1 + .2 + :1 + DO (1550) NEXT + PLEASE DO .3 <- :3 + DO RETRIEVE :1 + :2 + :3 + DO RESUME #1 + (1050) PLEASE STASH :2 + :3 + .5 + DO :2 <- .1 + PLEASE DO (1550) NEXT + DO .5 <- :3~'#21760$#21760' + DO .5 <- '?"!5~.5'~#3"$#4'~#4 + DO (1051) NEXT + DO (1999) NEXT + (1051) DO (1001) NEXT + DO .2 <- :3 + PLEASE RETRIEVE :2 + :3 + .5 + DO RESUME #2 + (1200) DO .2 <- '^.1$.1'~'#0$#21845' + DO .3 <- '?"'@.1$#0'~'#0$#21845'"$"'@.1$#65535' + ~'#0$#21845'"'~'#0$#21845' + DO .2 <- '^.2$"!3$#0'~'#5461$#1'"'~'#0$#21845' + DO .3 <- .3~#16384 + PLEASE RESUME #1 + (1210) DO .2 <- '?"'@.1$#0'~'#0$#21845'"$"'@.1$#65535' + ~'#0$#21845'"'~'#0$#21845' + DO .3 <- '^.1$.1'~'#0$#21845' + DO .2 <- '^.2$".3~#21844"'~'#0$#21845' + DO .3 <- .3~#1 + PLEASE RESUME #1 + (1500) PLEASE ABSTAIN FROM (1502) + PLEASE ABSTAIN FROM (1506) + (1509) PLEASE STASH :1 + .1 + .2 + .3 + .4 + .5 + .6 + DO .1 <- :1~#21845 + PLEASE DO .2 <- :2~#21845 + DO (1009) NEXT + DO .5 <- .3 + PLEASE DO .6 <- .4 + DO .1 <- :1~'#21760$#21760' + DO .2 <- :2~'#21760$#21760' + DO (1009) NEXT + DO .1 <- .3 + PLEASE DO (1503) NEXT + DO .6 <- .4 + DO .2 <- #1 + DO (1009) NEXT + DO .1 <- .3 + DO (1501) NEXT + (1504) PLEASE RESUME .6 + (1503) DO (1504) NEXT + (1501) DO .2 <- .5 + DO .5 <- '&.6$.4' + DO (1505) NEXT + (1506) DO (1502) NEXT + PLEASE DO (1999) NEXT + (1505) DO (1001) NEXT + (1502) DO :4 <- .5 + DO (1520) NEXT + DO :3 <- :1 + PLEASE RETRIEVE :1 + .1 + .2 + .3 + .4 + .5 + .6 + DO REINSTATE (1502) + DO REINSTATE (1506) + PLEASE RESUME #3 + (1510) DO STASH :1 + :2 + :4 + DO :1 <- "'?#65535$":2~'#21845$#0'"'~'#0$#21845'"$ + "'?#65535$":2~'#0$#21845'"'~'#0$#21845'" + DO :2 <- #1 + DO (1509) NEXT + PLEASE RETRIEVE :1 + DO :2 <- :3 + PLEASE DO (1509) NEXT + DO RETRIEVE :2 + :4 + PLEASE RESUME #1 + (1520) PLEASE STASH .3 + .4 + DO .3 <- .1~#17476 + DO (1525) NEXT + PLEASE DO .4 <- 'V.3$".2~#17476"'~'#0$#21845' + DO .3 <- .1~#4369 + PLEASE DO (1525) NEXT + DO :1 <- .4$"'V.3$".2~#4369"'~'#0$#21845'" + PLEASE RETRIEVE .3 + .4 + DO RESUME #1 + (1525) DO .3 <- '"'"!3$#0'~'#5461$#1'"$#0'~'#5461$#1'"$ + #0'~'#1365$#5' + PLEASE RESUME #1 + (1530) DO STASH :2 + :3 + .1 + .2 + .3 + DO :3 <- #0 + DO :2 <- .1 + DO (1535) NEXT + (1535) PLEASE FORGET #1 + DO .3 <- '?"!2~.2'~#3"$#4'~#4 + DO (1532) NEXT + DO .1 <- .2 + DO (1210) NEXT + DO .3 <- 'V.3$#1'~#1 + DO (1531) NEXT + DO :1 <- :3 + DO (1500) NEXT + PLEASE DO (1533) NEXT + (1531) PLEASE DO (1534) NEXT + (1533) DO FORGET #1 + DO :1 <- :2 + DO (1700) NEXT + DO (1535) NEXT + (1534) PLEASE RESUME .3 + (1532) DO (1534) NEXT + DO :1 <- :3 + PLEASE RETRIEVE :2 + :3 + .1 + .2 + .3 + DO RESUME #2 + (1540) PLEASE ABSTAIN FROM (1541) + DO ABSTAIN FROM (1542) + (1549) PLEASE STASH :1 + :2 + :4 + :5 + .1 + .2 + .5 + DO .1 <- :1~#21845 + PLEASE DO .2 <- :2~'#21760$#21760' + DO .5 <- :1~'#21760$#21760' + DO (1530) NEXT + DO :3 <- :1 + DO .2 <- :2~#21845 + PLEASE DO (1530) NEXT + DO :5 <- :1 + DO .1 <- .5 + DO (1530) NEXT + DO :4 <- :1 + PLEASE DO :1 <- ":3~'#21760$#21760'"$":4 + ~'#21760$#21760'" + DO .5 <- ':1~:1'~#3 + DO .2 <- :2~'#21760$#21760' + DO (1530) NEXT + PLEASE DO .5 <- '"':1~:1'~#3"$.5'~#5 + DO .1 <- :3~#21845 + DO .2 <- #0 + DO (1520) NEXT + PLEASE DO :2 <- :1 + PLEASE DO .1 <- :4~#21845 + DO (1520) NEXT + DO (1509) NEXT + DO .5 <- !5$"'^":4~#1"$#1'~#1"'~#69 + DO :1 <- :3 + DO :2 <- :5 + DO (1509) NEXT + PLEASE DO .5 <- !5$"'^":4~#1"$#1'~#1"'~#1093 + DO .5 <- '?"!5~.5'~#1"$#1'~#1 + PLEASE RETRIEVE :4 + (1541) DO :4 <- .5 + DO (1543) NEXT + (1542) DO (1544) NEXT + PLEASE DO (1999) NEXT + (1543) DO (1001) NEXT + (1544) DO REINSTATE (1541) + PLEASE REINSTATE (1542) + PLEASE RETRIEVE :1 + :2 + :5 + .1 + .2 + .5 + DO RESUME #2 + (1550) DO STASH :1 + :1 + :4 + :5 + :6 + .1 + .5 + DO :3 <- #0 + DO .5 <- '?"':2~:2'~#3"$#4'~#4 + PLEASE DO (1551) NEXT + DO :4 <- #1 + PLEASE DO (1553) NEXT + (1553) DO FORGET #1 + DO .5 <- '?#0$"'V"'@":2~'#16384$#0'"$#3'~#1"$#2' + ~#1"'~#1 + DO (1552) NEXT + DO :5 <- :2 + DO :1 <- :4 + PLEASE DO (1700) NEXT + DO :4 <- :2 + DO :1 <- :5 + PLEASE DO (1700) NEXT + DO (1553) NEXT + (1552) DO (1001) NEXT + DO RETRIEVE :1 + (1556) PLEASE FORGET #1 + DO :6 <- "'&":2~'#21845$#0'"$"'?#65535$":1 + ~'#21845$#0'"'~'#0$#21845'"'~'#0$#21845'"$ + "'&":2~'#0$#21845'"$"'?#65535$":1~'#0$ + #21845'"'~'#0$#21845'"'~'#0$#21845'" + DO :6 <- "'?"'V":6~'#21845$#0'"$#21845'~'#0$ + #21845'"$#21845'~'#0$#65535'"$"'?"'V":6 + ~'#0$#21845'"$#21845'~'#0$#21845'"$#21845' + ~'#0$#65535'" + DO :5 <- "'?":1~'#21845$#0'"$":2~'#21845$#0'"' + ~'#0$#65535'"$"'?":1~'#0$#21845'"$":2~'#0$ + #21845'"'~'#0$#65535'" + DO .5 <- "?'"':6~:5'~'"'"'&"':5~:5'~'#21845$#0'"$ + #16384'~'#0$#21845'"$"'?:5~:5'~'#5461$#0'"' + ~'#16384$#5461'"$"'?:5~:5'~'#0$#21845'"'" + ~#1'$#2"~#1 + DO (1554) NEXT + DO :5 <- :3 + DO (1510) NEXT + PLEASE DO :1 <- :3 + DO :3 <- "'^":4~'#21845$#0'"$":5~'#21845$#0'"' + ~'#0$#21845'"$"'^":4~'#0$#21845'"$":5~'#0$ + #21845'"'~'#0$#21845'" + DO (1555) NEXT + (1554) PLEASE DO (1001) NEXT + (1555) DO FORGET #1 + DO .5 <- 'V":4~#1"$"'?#2$":4~#1"'~#1"'~#1 + DO (1551) NEXT + DO :5 <- :1 + DO :1 <- :4 + DO :4 <- :2 + DO (1710) NEXT + DO :1 <- :4 + DO :4 <- :2 + DO (1710) NEXT + DO :1 <- :5 + PLEASE DO (1556) NEXT + (1551) DO (1001) NEXT + PLEASE RETRIEVE :1 + :4 + :5 + :6 + .1 + .5 + PLEASE RESUME #2 + (1700) PLEASE STASH .2 + DO .1 <- :1~'#0$#21845' + DO .2 <- :1~'#21845$#0' + DO :2 <- "'^.2$.2'~'#0$#21845'"$"'^.1$.1'~'#0$ + #21845'" + DO .1 <- '?"'@.1$#0'~'#0$#21845'"$"'@.1$#65535' + ~'#0$#21845'"'~'#0$#21845' + DO .2 <- '?"'@.2$#0'~'#0$#21845'"$"'@.2$#65535' + ~'#0$#21845'"'~'#0$#21845' + DO :2 <- "'^":2~'#21845$#0'"$.1'~'#0$#21845'"$ + "'^":2~'#0$#21845'"$"'.2$#0'~'#5461$#1'"' + ~'#0$#21845'" + DO .1 <- .2~#16384 + PLEASE RETRIEVE .2 + PLEASE RESUME #1 + (1710) PLEASE STASH :1 + .2 + DO .1 <- :1~'#0$#21845' + DO .2 <- :1~'#21845$#0' + DO :2 <- "'^.2$.2'~'#0$#21845'"$"'^.1$.1'~'#0$ + #21845'" + DO :1 <- "'?"'@.2$#0'~'#0$#21845'"$"'@.2$#65535' + ~'#0$#21845'"'~'#0$#21845'"$"'?"'@.1$#0' + ~'#0$#21845'"$"'@.1$#65535'~'#0$#21845'"' + ~'#0$#21845'" + DO .1 <- :2~#1 + DO :2 <- "'^":1~'#21845$#0'"$":2~'#0$#21844'"' + ~'#0$#21845'"$"'^":1~'#0$#21845'"$":2 + ~'#21845$#0'"'~'#0$#21845'" + PLEASE RETRIEVE :1 + .2 + PLEASE RESUME #1 + (1900) DO STASH .2 + .5 + DO .1 <- #0 + DO .2 <- #1 + PLEASE DO (1901) NEXT + (1901) PLEASE FORGET #1 + DO %50 .1 <- 'V.1$.2'~'#0$#21845' + DO %50 .1 <- '^.1$".2~#43690"'~'#0$#21845' + DO .2 <- !2$#0'~'#5461$#1' + PLEASE DO .5 <- '^".2~.2"$#1'~#1 + DO (1902) NEXT + DO (1901) NEXT + (1902) DO (1001) NEXT + DO RETRIEVE .2 + .5 + PLEASE RESUME #2 + (1910) PLEASE STASH .1 + .3 + .5 + :1 + :2 + :3 + DO .3 <- #65524 + DO :1 <- #6 + DO (1911) NEXT + PLEASE NOTE THAT YOU CAN'T GET ANYWHERE FROM HERE + (1912) DO (1001) NEXT + (1911) DO FORGET #1 + PLEASE DO (1900) NEXT + DO :2 <- .1 + DO (1500) NEXT + PLEASE DO :1 <- :3 + DO .1 <- .3 + DO (1020) NEXT + PLEASE DO .3 <- .1 + DO .5 <- '?"!3~.3'~#3"$#2'~#1 + DO (1912) NEXT + DO .1 <- #12 + PLEASE DO (1050) NEXT + DO RETRIEVE .1 + DO (1530) NEXT + DO :2 <- #32768 + DO (1500) NEXT + PLEASE DO .2 <- :3~'#21760$#21760' + PLEASE RETRIEVE .3 + .5 + :1 + :2 + :3 + DO RESUME #1 diff --git a/pit/lib/syslib.5i b/pit/lib/syslib.5i new file mode 100644 index 0000000..518b7cd --- /dev/null +++ b/pit/lib/syslib.5i @@ -0,0 +1,355 @@ + PLEASE KNOCK "SHAVE-AND-A-HAIRCUT" BEFORE ENTERING + + (1000) PLEASE IGNORE .4 + PLEASE ABSTAIN FROM (1005) + (1009) DO STASH .1 + .2 + .5 + .6 + DO .4 <- #1 + DO (1004) NEXT + (1004) PLEASE FORGET #1 + DO .3 <- '^.1$.2'~'#0$#3906' + DO .6 <- '?"'V"'&.1$.2'~'#0$#3906'"$"'^"'@.1$ + .2'~'#0$#3906'"$#3906'~'#0$#11718'"' + ~'#0$#3906'"$#11718'~'#0$#3906' + PLEASE DO .5 <- "?!6~#12500'$#5"~#5 + DO (1002) NEXT + DO .4 <- #2 + (1005) DO (1006) NEXT + (1999) DOUBLE OR SINGLE PRECISION OVERFLOW + (1002) DO (1001) NEXT + (1006) PLEASE FORGET #1 + DO .5 <- '?"!6~.6'~#4"$#5'~#5 + DO (1003) NEXT + DO .1 <- .3 + DO .2 <- !6$#0'~'#781$#1' + DO (1004) NEXT + (1003) DO (1001) NEXT + DO REINSTATE (1005) + (1007) PLEASE RETRIEVE .1 + .2 + .5 + .6 + DO REMEMBER .4 + PLEASE RESUME #2 + (1001) DO RESUME .5 + (1010) DO STASH .1 + .2 + .4 + DO .4 <- .1 + DO .1 <- '?#15624$.2'~'#0$#3906' + DO (1020) NEXT + PLEASE DO .2 <- .4 + PLEASE DO (1009) NEXT + DO RETRIEVE .1 + .2 + .4 + PLEASE RESUME #1 + (1020) DO STASH .2 + .3 + DO .2 <- #1 + PLEASE DO (1021) NEXT + (1021) DO FORGET #1 + DO .3 <- '?"'V".1~.2"$#3'~#1"$#2'~#1 + PLEASE DO .1 <- '^.1$.2'~'#0$#3906' + DO (1022) NEXT + DO .2 <- !2$#0'~'#781$#1' + DO (1021) NEXT + (1023) PLEASE RESUME .3 + (1022) DO (1023) NEXT + PLEASE RETRIEVE .2 + .3 + PLEASE RESUME #2 + (1030) DO ABSTAIN FROM (1033) + PLEASE ABSTAIN FROM (1032) + (1039) DO STASH :1 + .5 + DO (1530) NEXT + DO .3 <- :1~#3906 + PLEASE DO .5 <- :1~'#3875$#3875' + DO .5 <- '?"!5~.5'~#4"$#5'~#5 + DO (1031) NEXT + (1032) DO (1033) NEXT + DO (1999) NEXT + (1031) DO (1001) NEXT + (1033) DO .4 <- .5 + DO REINSTATE (1032) + PLEASE REINSTATE (1033) + DO RETRIEVE :1 + .5 + PLEASE RESUME #2 + (1040) PLEASE STASH .1 + .2 + .2 + :1 + :2 + :3 + DO .2 <- #0 + DO (1520) NEXT + DO STASH :1 + PLEASE RETRIEVE .2 + DO .1 <- .2 + DO .2 <- #0 + PLEASE DO (1520) NEXT + DO :2 <- :1 + DO RETRIEVE .1 + .2 + :1 + DO (1550) NEXT + PLEASE DO .3 <- :3 + DO RETRIEVE :1 + :2 + :3 + DO RESUME #1 + (1050) PLEASE STASH :2 + :3 + .5 + DO :2 <- .1 + PLEASE DO (1550) NEXT + DO .5 <- :3~'#3875$#3875' + DO .5 <- '?"!5~.5'~#4"$#5'~#5 + DO (1051) NEXT + DO (1999) NEXT + (1051) DO (1001) NEXT + DO .2 <- :3 + PLEASE RETRIEVE :2 + :3 + .5 + DO RESUME #2 + (1500) PLEASE ABSTAIN FROM (1502) + PLEASE ABSTAIN FROM (1506) + (1509) PLEASE STASH :1 + .1 + .2 + .3 + .4 + .5 + .6 + DO .1 <- :1~#3906 + PLEASE DO .2 <- :2~#3906 + DO (1009) NEXT + DO .5 <- .3 + PLEASE DO .6 <- .4 + DO .1 <- :1~'#3875$#3875' + DO .2 <- :2~'#3875$#3875' + DO (1009) NEXT + DO .1 <- .3 + PLEASE DO (1503) NEXT + DO .6 <- .4 + DO .2 <- #1 + DO (1009) NEXT + DO .1 <- .3 + DO (1501) NEXT + (1504) PLEASE RESUME .6 + (1503) DO (1504) NEXT + (1501) DO .2 <- .5 + DO .5 <- '&.6$.4' + DO (1505) NEXT + (1506) DO (1502) NEXT + PLEASE DO (1999) NEXT + (1505) DO (1001) NEXT + (1502) DO :4 <- .5 + DO (1520) NEXT + DO :3 <- :1 + PLEASE RETRIEVE :1 + .1 + .2 + .3 + .4 + .5 + .6 + DO REINSTATE (1502) + DO REINSTATE (1506) + PLEASE RESUME #3 + (1510) DO STASH :1 + :2 + :4 + DO :1 <- "'?#15624$":2~'#3906$#0'"'~'#0$#3906'"$ + "'?#15624$":2~'#0$#3906'"'~'#0$#3906'" + DO :2 <- #1 + DO (1509) NEXT + PLEASE RETRIEVE :1 + DO :2 <- :3 + PLEASE DO (1509) NEXT + DO RETRIEVE :2 + :4 + PLEASE RESUME #1 + (1520) PLEASE STASH .3 + .4 + DO .3 <- .1~#3255 + DO (1525) NEXT + PLEASE DO .4 <- 'V.3$".2~#3255"'~'#0$#3906' + DO .3 <- .1~#651 + PLEASE DO (1525) NEXT + DO :1 <- .4$"'V.3$".2~#651"'~'#0$#3906'" + PLEASE RETRIEVE .3 + .4 + DO RESUME #1 + (1525) DO .3 <- '"!3$#0'~'#781$#1'"$#0'~'#156$#6' + PLEASE RESUME #1 + (1530) DO STASH :2 + :3 + :4 + .1 + .2 + .5 + DO :3 <- #0 + DO :4 <- .2 + DO (1535) NEXT + (1535) PLEASE FORGET #1 + DO .5 <- '?".1~#4"$#5'~#5 + DO (1531) NEXT + DO :1 <- :4 + DO (1720) NEXT + DO :1 <- :3 + DO (1500) NEXT + PLEASE DO (1533) NEXT + (1531) PLEASE DO (1001) NEXT + (1533) DO FORGET #1 + DO .1 <- .1~#3905 + DO :4 <- ":4~'#0$#3906'"$"'":4~'#781$#0'"$#0' + ~'#781$#1'" + PLEASE DO .5 <- '?"!1~.1'~#4"$#5'~#5 + DO (1532) NEXT + DO (1535) NEXT + (1532) DO (1001) NEXT + DO :1 <- :3 + PLEASE RETRIEVE :2 + :3 + :4 + .1 + .2 + .5 + DO RESUME #2 + (1540) PLEASE ABSTAIN FROM (1541) + DO ABSTAIN FROM (1542) + (1549) PLEASE STASH :1 + :2 + :4 + :5 + .1 + .2 + .5 + DO .1 <- :1~#3906 + PLEASE DO .2 <- :2~'#3875$#3875' + DO .5 <- :1~'#3875$#3875' + DO (1530) NEXT + DO :3 <- :1 + DO .2 <- :2~#3906 + PLEASE DO (1530) NEXT + DO :5 <- :1 + DO .1 <- .5 + DO (1530) NEXT + DO :4 <- :1 + PLEASE DO :1 <- ":3~'#3875$#3875'"$":4 + ~'#3875$#3875'" + DO .5 <- ':1~:1'~#4 + DO .2 <- :2~'#3875$#3875' + DO (1530) NEXT + PLEASE DO .5 <- '"':1~:1'~#4"$.5'~#6 + DO .1 <- :3~#3906 + DO .2 <- #0 + DO (1520) NEXT + PLEASE DO :2 <- :1 + PLEASE DO .1 <- :4~#3906 + DO (1520) NEXT + DO (1509) NEXT + DO .5 <- !5$"'^":4~#1"$#2'~#1"'~#131 + DO :1 <- :3 + DO :2 <- :5 + DO (1509) NEXT + PLEASE DO .5 <- !5$"'^":4~#1"$#2'~#1"'~#3256 + DO .5 <- '?"!5~.5'~#1"$#2'~#1 + PLEASE RETRIEVE :4 + (1541) DO :4 <- .5 + DO (1543) NEXT + (1542) DO (1544) NEXT + PLEASE DO (1999) NEXT + (1543) DO (1001) NEXT + (1544) DO REINSTATE (1541) + PLEASE REINSTATE (1542) + PLEASE RETRIEVE :1 + :2 + :5 + .1 + .2 + .5 + DO RESUME #2 + (1550) DO STASH :1 + :4 + :5 + :6 + .1 + .5 + DO :5 <- #0 + DO .5 <- '?"':2~:2'~#4"$#5'~#5 + PLEASE DO (1551) NEXT + DO :4 <- #1 + PLEASE DO (1553) NEXT + (1553) DO FORGET #1 + DO .5 <- '?"':2~"#12500$#0"'"$#3'~#1 + DO (1552) NEXT + DO :2 <- ":2~'#0$#3906'"$"'":2~'#781$#0'"$#0' + ~'#781$#1'" + PLEASE DO :4 <- ":4~'#0$#3906'"$"'":4~'#781 + $#0'"$#0'~'#781$#1'" + DO (1553) NEXT + (1552) DO (1001) NEXT + DO .1 <- #0 + (1556) PLEASE FORGET #1 + DO :6 <- "'&":2~'#3906$#0'"$"'?#15624$":1 + ~'#3906$#0'"'~'#0$#3906'"'~'#0$#3906'"$ + "'&":2~'#0$#3906'"$"'?#15624$":1~'#0$ + #3906'"'~'#0$#3906'"'~'#0$#3906'" + DO :6 <- "'?"'V":6~'#3906$#0'"$#7812'~'#0$ + #3906'"$#7812'~'#0$#15624'"$"'?"'V":6 + ~'#0$#3906'"$#7812'~'#0$#3906'"$#7812' + ~'#0$#15624'" + DO :3 <- "'?":1~'#3906$#0'"$":2~'#3906$#0'"' + ~'#0$#15624'"$"'?":1~'#0$#3906'"$":2~'#0$ + #3906'"'~'#0$#15624'" + DO .5 <- "?'"':6~:3'~'"'"'&"':3~:3'~'#3906$#0'"$ + #3125'~'#0$#3906'"$"'?:3~:3'~'#781$#0'"' + ~'#3125$#781'"$"'?:3~:3'~'#0$#3906'"'"~#1'$ + #3"~#1 + PLEASE DO (1557) NEXT + DO (1510) NEXT + PLEASE DO :1 <- :3 + DO .5 <- '?#0$"'V.1$#3'~#1"'~#1 + DO (1557) NEXT + DO .1 <- '^.1$#3906'~'#0$#3906' + DO (1556) NEXT + (1557) PLEASE DO (1001) NEXT + PLEASE FORGET #1 + DO :5 <- "'V":4~'.1$#0'"$":5~'#3906$#0'"' + ~'#0$#3906'"$"'V":4~'#0$.1'"$":5~'#0$ + #3906'"'~'#0$#3906'" + DO .5 <- "?#2$':4~#1'"~#1 + DO (1551) NEXT + DO :2 <- :2~'#3906$#3905' + DO :4 <- :4~'#3906$#3905' + DO .1 <- #0 + PLEASE DO (1556) NEXT + (1551) DO (1001) NEXT + DO :3 <- :5 + PLEASE RETRIEVE :1 + :4 + :5 + :6 + .1 + .5 + PLEASE RESUME #2 + (1720) PLEASE STASH :1 + :3 + :4 + .1 + .5 + DO :2 <- #0 + DO .2 <- #0 + DO .5 <- '?".1~#4"$#5'~#5 + DO (1729) NEXT + DO .5 <- .1~#1 + DO .2 <- :1~'#3906$#0' + DO .1 <- :1~'#0$#3906' + PLEASE DO (1724) NEXT + DO :1 <- '"?#0$.2"~"#0$#3906"'$'"?#0$.1"~"#0$ + #3906"' + DO :2 <- '"?'"V.2$#3906"~"#0$#3906"'$ + #3906"~"#0$#3906"'$'"?'"V.1$#3906" + ~"#0$#3906"'$#3906"~"#0$#3906"' + DO (1728) NEXT + (1724) PLEASE DO (1723) NEXT + DO :1 <- '"?#0$'"^.2$.2"~"#0$#3906"'"~"#0$#3906"'$ + '"?#0$'"^.1$.1"~"#0$#3906"'"~"#0$#3906"' + DO :2 <- '"?'"V'"@.2$#11718"~"#0$#3906"'$#7812" + ~"#0$#3906"'$#7812"~"#0$#3906"'$'"?'"V'"@.1$ + #11718"~"#0$#3906"'$#7812"~"#0$#3906"'$#7812" + ~"#0$#3906"' + (1728) DO .2 <- :2~'#3125$#0' + DO :2 <- ':2~"#0$#3906"'$'"':2~"#781$#0"'$#0" + ~"#781$#1"' + DO (1509) NEXT + DO :2 <- :3 + DO .2 <- '^.2$"'?":4~#1"$#1'~#1"'~#1 + DO (1721) NEXT + (1723) PLEASE DO (1722) NEXT + DO :1 <- '"^.2$.2"~"#0$#3906"'$'"^.1$.1"~"#0$ + #3906"' + DO :2 <- '"?'"V'"2@.2$#15624"~"#0$#3906"'$ + #11718"~"#0$#3906"'$#11718"~"#0$#3906"'$ + '"?'"V'"2@.1$#15624"~"#0$#3906"'$#11718" + ~"#0$#3906"'$#11718"~"#0$#3906"' + PLEASE FORGET #2 + DO (1728) NEXT + (1729) DO (1001) NEXT + DO (1721) NEXT + (1722) PLEASE DO (1001) NEXT + DO :2 <- :1 + DO .2 <- #0 + DO FORGET #1 + (1721) PLEASE RETRIEVE :1 + :3 + :4 + .1 + .5 + PLEASE RESUME #3 + (1900) DO STASH .2 + .5 + DO .1 <- #0 + DO .2 <- #1 + PLEASE DO (1901) NEXT + (1901) DO %20 (1903) NEXT + DO .1 <- 'V.1$.2'~'#0$#3906' + DO %50 .1 <- '^.1$".2~#7812"'~'#0$#3906' + DO %50 .1 <- '^.1$.2'~'#0$#3906' + PLEASE DO (1903) NEXT + (1903) PLEASE FORGET #2 + DO .2 <- !2$#0'~'#781$#1' + PLEASE DO .5 <- '^".2~.2"$#1'~#1 + DO (1902) NEXT + DO (1901) NEXT + (1902) DO (1001) NEXT + DO RETRIEVE .2 + .5 + PLEASE RESUME #2 + (1910) PLEASE STASH .1 + .3 + .5 + :1 + :2 + :3 + DO .3 <- #15613 + DO :1 <- #6 + DO (1911) NEXT + PLEASE NOTE THAT YOU CAN'T GET SOMETHING FROM NOTHING + (1912) DO (1001) NEXT + (1911) DO FORGET #1 + PLEASE DO (1900) NEXT + DO :2 <- .1 + DO (1500) NEXT + PLEASE DO :1 <- :3 + DO .1 <- .3 + DO (1020) NEXT + PLEASE DO .3 <- .1 + DO .5 <- '?"!3~.3'~#4"$#3'~#1 + DO (1912) NEXT + DO .1 <- #12 + PLEASE DO (1050) NEXT + DO RETRIEVE .1 + DO (1530) NEXT + DO :2 <- #7812 + DO (1500) NEXT + PLEASE DO .2 <- :3~'#3875$#3875' + PLEASE RETRIEVE .3 + .5 + :1 + :2 + :3 + DO RESUME #1 diff --git a/pit/lib/syslib.6i b/pit/lib/syslib.6i new file mode 100644 index 0000000..156a59f --- /dev/null +++ b/pit/lib/syslib.6i @@ -0,0 +1,373 @@ + PLEASE KNOCK THRICE TWO TIMES BEFORE ENTERING + + (1000) PLEASE IGNORE .4 + PLEASE ABSTAIN FROM (1005) + (1009) DO STASH .1 + .2 + .5 + .6 + DO .4 <- #1 + DO (1004) NEXT + (1004) PLEASE FORGET #1 + DO .3 <- '^.1$.2'~'#0$#9331' + DO .6 <- '?"'V"'V"'&.1$.2'~'#0$#9331'"$"'^"'@.1$ + .2'~'#0$#9331'"$#9331'~'#0$#9331'"'~'#0$ + #9331'"$"'^"'2@.1$.2'~'#0$#9331'"$#18662' + ~'#0$#9331'"'~'#0$#37324'"$#37324'~'#0$#9331' + PLEASE DO .5 <- "?!6~#38880'$#6"~#6 + DO (1002) NEXT + DO .4 <- #2 + (1005) DO (1006) NEXT + (1999) DOUBLE OR SINGLE PRECISION OVERFLOW + (1002) DO (1001) NEXT + (1006) PLEASE FORGET #1 + DO .5 <- '?"!6~.6'~#5"$#6'~#6 + DO (1003) NEXT + DO .1 <- .3 + DO .2 <- !6$#0'~'#1555$#1' + DO (1004) NEXT + (1003) DO (1001) NEXT + DO REINSTATE (1005) + (1007) PLEASE RETRIEVE .1 + .2 + .5 + .6 + DO REMEMBER .4 + PLEASE RESUME #2 + (1001) DO RESUME .5 + (1010) DO STASH .1 + .2 + .4 + DO .4 <- .1 + DO .1 <- '?#46655$.2'~'#0$#9331' + DO (1020) NEXT + PLEASE DO .2 <- .4 + PLEASE DO (1009) NEXT + DO RETRIEVE .1 + .2 + .4 + PLEASE RESUME #1 + (1020) DO STASH .2 + .3 + DO .2 <- #1 + PLEASE DO (1021) NEXT + (1021) DO FORGET #1 + DO .3 <- '?"'V".1~.2"$#4'~#1"$#3'~#1 + PLEASE DO .1 <- '^.1$.2'~'#0$#9331' + DO (1022) NEXT + DO .2 <- !2$#0'~'#1555$#1' + DO (1021) NEXT + (1023) PLEASE RESUME .3 + (1022) DO (1023) NEXT + PLEASE RETRIEVE .2 + .3 + PLEASE RESUME #2 + (1030) DO ABSTAIN FROM (1033) + PLEASE ABSTAIN FROM (1032) + (1039) DO STASH :1 + .5 + DO (1530) NEXT + DO .3 <- :1~#9331 + PLEASE DO .5 <- :1~'#9288$#9288' + DO .5 <- '?"!5~.5'~#5"$#6'~#6 + DO (1031) NEXT + (1032) DO (1033) NEXT + DO (1999) NEXT + (1031) DO (1001) NEXT + (1033) DO .4 <- .5 + DO REINSTATE (1032) + PLEASE REINSTATE (1033) + DO RETRIEVE :1 + .5 + PLEASE RESUME #2 + (1040) PLEASE STASH .1 + .2 + .2 + :1 + :2 + :3 + DO .2 <- #0 + DO (1520) NEXT + DO STASH :1 + PLEASE RETRIEVE .2 + DO .1 <- .2 + DO .2 <- #0 + PLEASE DO (1520) NEXT + DO :2 <- :1 + DO RETRIEVE .1 + .2 + :1 + DO (1550) NEXT + PLEASE DO .3 <- :3 + DO RETRIEVE :1 + :2 + :3 + DO RESUME #1 + (1050) PLEASE STASH :2 + :3 + .5 + DO :2 <- .1 + PLEASE DO (1550) NEXT + DO .5 <- :3~'#9288$#9288' + DO .5 <- '?"!5~.5'~#5"$#6'~#6 + DO (1051) NEXT + DO (1999) NEXT + (1051) DO (1001) NEXT + DO .2 <- :3 + PLEASE RETRIEVE :2 + :3 + .5 + DO RESUME #2 + (1200) DO .2 <- '^.1$.1'~'#0$#9331' + DO .3 <- '?"'2@.1$#0'~'#0$#9331'"$"'2@.1$#46655' + ~'#0$#9331'"'~'#0$#9331' + DO .2 <- '^.2$"!3$#0'~'#1555$#1'"'~'#0$#9331' + DO .3 <- .3~#7776 + PLEASE RESUME #1 + (1210) DO .2 <- '^"'?"'@.1$#0'~'#0$#9331'"$"'@.1$#46655' + ~'#0$#9331'"'~'#0$#9331'"$"'?"'3@.1$#0'~'#0$ + #9331'"$"'3@.1$#46655'~'#0$#9331'"'~'#0$ + #9331'"'~'#0$#9331' + DO .3 <- '^"'^.1$.1'~'#0$#9331'"$.1'~'#0$#9331' + DO .2 <- '^.2$".3~#9330"'~'#0$#9331' + DO .3 <- .3~#1 + PLEASE RESUME #1 + (1500) PLEASE ABSTAIN FROM (1502) + PLEASE ABSTAIN FROM (1506) + (1509) PLEASE STASH :1 + .1 + .2 + .3 + .4 + .5 + .6 + DO .1 <- :1~#9331 + PLEASE DO .2 <- :2~#9331 + DO (1009) NEXT + DO .5 <- .3 + PLEASE DO .6 <- .4 + DO .1 <- :1~'#9288$#9288' + DO .2 <- :2~'#9288$#9288' + DO (1009) NEXT + DO .1 <- .3 + PLEASE DO (1503) NEXT + DO .6 <- .4 + DO .2 <- #1 + DO (1009) NEXT + DO .1 <- .3 + DO (1501) NEXT + (1504) PLEASE RESUME .6 + (1503) DO (1504) NEXT + (1501) DO .2 <- .5 + DO .5 <- '&.6$.4' + DO (1505) NEXT + (1506) DO (1502) NEXT + PLEASE DO (1999) NEXT + (1505) DO (1001) NEXT + (1502) DO :4 <- .5 + DO (1520) NEXT + DO :3 <- :1 + PLEASE RETRIEVE :1 + .1 + .2 + .3 + .4 + .5 + .6 + DO REINSTATE (1502) + DO REINSTATE (1506) + PLEASE RESUME #3 + (1510) DO STASH :1 + :2 + :4 + DO :1 <- "'?#46655$":2~'#9331$#0'"'~'#0$#9331'"$ + "'?#46655$":2~'#0$#9331'"'~'#0$#9331'" + DO :2 <- #1 + DO (1509) NEXT + PLEASE RETRIEVE :1 + DO :2 <- :3 + PLEASE DO (1509) NEXT + DO RETRIEVE :2 + :4 + PLEASE RESUME #1 + (1520) PLEASE STASH .3 + .4 + DO .3 <- .1~#7998 + DO (1525) NEXT + PLEASE DO .4 <- 'V.3$".2~#7998"'~'#0$#9331' + DO .3 <- .1~#1333 + PLEASE DO (1525) NEXT + DO :1 <- .4$"'V.3$".2~#1333"'~'#0$#9331'" + PLEASE RETRIEVE .3 + .4 + DO RESUME #1 + (1525) DO .3 <- '"!3$#0'~'#1555$#1'"$#0'~'#259$#7' + PLEASE RESUME #1 + (1530) DO STASH :2 + :3 + .1 + .2 + .3 + DO :3 <- #0 + DO :2 <- .1 + DO (1535) NEXT + (1535) PLEASE FORGET #1 + DO .3 <- '?"!2~.2'~#5"$#6'~#6 + DO (1532) NEXT + DO .1 <- .2 + DO (1210) NEXT + DO .3 <- '?#1$".3~#5"'~#1 + DO (1531) NEXT + DO :1 <- :3 + DO (1500) NEXT + PLEASE DO (1533) NEXT + (1531) PLEASE DO (1534) NEXT + (1533) DO FORGET #1 + DO :1 <- :2 + DO (1700) NEXT + DO (1535) NEXT + (1534) PLEASE RESUME .3 + (1532) DO (1534) NEXT + DO :1 <- :3 + PLEASE RETRIEVE :2 + :3 + .1 + .2 + .3 + DO RESUME #2 + (1540) PLEASE ABSTAIN FROM (1541) + DO ABSTAIN FROM (1542) + (1549) PLEASE STASH :1 + :2 + :4 + :5 + .1 + .2 + .5 + DO .1 <- :1~#9331 + PLEASE DO .2 <- :2~'#9288$#9288' + DO .5 <- :1~'#9288$#9288' + DO (1530) NEXT + DO :3 <- :1 + DO .2 <- :2~#9331 + PLEASE DO (1530) NEXT + DO :5 <- :1 + DO .1 <- .5 + DO (1530) NEXT + DO :4 <- :1 + PLEASE DO :1 <- ":3~'#9288$#9288'"$":4 + ~'#9288$#9288'" + DO .5 <- ':1~:1'~#5 + DO .2 <- :2~'#9288$#9288' + DO (1530) NEXT + PLEASE DO .5 <- '"':1~:1'~#5"$.5'~#7 + DO .1 <- :3~#9331 + DO .2 <- #0 + DO (1520) NEXT + PLEASE DO :2 <- :1 + PLEASE DO .1 <- :4~#9331 + DO (1520) NEXT + DO (1509) NEXT + DO .5 <- !5$"'^":4~#1"$#3'~#1"'~#223 + DO :1 <- :3 + DO :2 <- :5 + DO (1509) NEXT + PLEASE DO .5 <- !5$"'^":4~#1"$#3'~#1"'~#7999 + DO .5 <- '?"!5~.5'~#1"$#3'~#1 + PLEASE RETRIEVE :4 + (1541) DO :4 <- .5 + DO (1543) NEXT + (1542) DO (1544) NEXT + PLEASE DO (1999) NEXT + (1543) DO (1001) NEXT + (1544) DO REINSTATE (1541) + PLEASE REINSTATE (1542) + PLEASE RETRIEVE :1 + :2 + :5 + .1 + .2 + .5 + DO RESUME #2 + (1550) DO STASH :1 + :1 + :4 + :5 + :6 + .1 + .5 + DO :3 <- #0 + DO .5 <- '?"':2~:2'~#5"$#6'~#6 + PLEASE DO (1551) NEXT + DO :4 <- #1 + PLEASE DO (1553) NEXT + (1553) DO FORGET #1 + DO .5 <- '?#0$"'V"'2@":2~'#7776$#0'"$#5'~#1"$#4' + ~#1"'~#1 + DO (1552) NEXT + DO :5 <- :2 + DO :1 <- :4 + PLEASE DO (1700) NEXT + DO :4 <- :2 + DO :1 <- :5 + PLEASE DO (1700) NEXT + DO (1553) NEXT + (1552) DO (1001) NEXT + DO RETRIEVE :1 + (1556) PLEASE FORGET #1 + DO :6 <- "'&":2~'#9331$#0'"$"'?#46655$":1 + ~'#9331$#0'"'~'#0$#9331'"'~'#0$#9331'"$ + "'&":2~'#0$#9331'"$"'?#46655$":1~'#0$ + #9331'"'~'#0$#9331'"'~'#0$#9331'" + DO :5 <- "'?":1~'#9331$#0'"$":2~'#9331$#0'"' + ~'#0$#9331'"$"'?":1~'#0$#9331'"$":2~'#0$ + #9331'"'~'#0$#9331'" + DO :6 <- "'&":6~'#9331$#0'"$":5~'#9331$#0'"' + ~'#0$#9331'"$"'&":6~'#0$#9331'"$":5~'#0$ + #9331'"'~'#0$#9331'" + DO :5 <- :5~'#46655$#46655' + DO :6 <- "'?"'V":6~'#9331$#0'"$#27993'~'#0$ + #9331'"$#27993'~'#0$#46655'"$"'?"'V":6 + ~'#0$#9331'"$#27993'~'#0$#9331'"$#27993' + ~'#0$#46655'" + DO .5 <- "?'"':6~:5'~'"'"'&"':5~:5'~'#9331$#0'"$ + #7776'~'#0$#9331'"$"'?:5~:5'~'#1555$#0'"' + ~'#7776$#1555'"$"'?:5~:5'~'#0$#9331'"'"~#1'$ + #4"~#1 + DO (1554) NEXT + DO :5 <- :3 + DO (1510) NEXT + DO :1 <- :4 + DO :4 <- :2 + DO :2 <- :5 + DO :5 <- :3 + DO (1500) NEXT + DO :2 <- :4 + DO :4 <- :1 + DO :1 <- :5 + DO (1555) NEXT + (1554) PLEASE DO (1001) NEXT + (1555) DO FORGET #1 + DO .5 <- '?#2$"'@#0$":4~#1"'~#1"'~#1 + DO (1551) NEXT + DO :5 <- :1 + DO :1 <- :4 + DO :4 <- :2 + DO (1710) NEXT + DO :1 <- :4 + DO :4 <- :2 + DO (1710) NEXT + DO :1 <- :5 + PLEASE DO (1556) NEXT + (1551) DO (1001) NEXT + PLEASE RETRIEVE :1 + :4 + :5 + :6 + .1 + .5 + PLEASE RESUME #2 + (1700) PLEASE STASH .2 + DO .1 <- :1~'#0$#9331' + DO .2 <- :1~'#9331$#0' + DO :2 <- "'^.2$.2'~'#0$#9331'"$"'^.1$.1'~'#0$ + #9331'" + DO .1 <- '?"'2@.1$#0'~'#0$#9331'"$"'2@.1$#46655' + ~'#0$#9331'"'~'#0$#9331' + DO .2 <- '?"'2@.2$#0'~'#0$#9331'"$"'2@.2$#46655' + ~'#0$#9331'"'~'#0$#9331' + DO :2 <- "'^":2~'#9331$#0'"$.1'~'#0$#9331'"$"'^":2 + ~'#0$#9331'"$"'.2$#0'~'#1555$#1'"'~'#0$#9331'" + DO .1 <- .2~#7776 + PLEASE RETRIEVE .2 + PLEASE RESUME #1 + (1710) PLEASE STASH :1 + .2 + DO .2 <- :1~'#9331$#0' + DO .1 <- :1~'#0$#9331' + DO :2 <- "'^"'^.2$.2'~'#0$#9331'"$.2'~'#0$ + #9331'"$"'^"'^.1$.1'~'#0$#9331'"$.1'~'#0$ + #9331'" + DO .1 <- '^"'?"'@.1$#0'~'#0$#9331'"$"'@.1$#46655' + ~'#0$#9331'"'~'#0$#9331'"$"'?"'3@.1$#0'~'#0$ + #9331'"$"'3@.1$#46655'~'#0$#9331'"'~'#0$ + #9331'"'~'#0$#9331' + DO :1 <- "'^"'?"'@.2$#0'~'#0$#9331'"$"'@.2$#46655' + ~'#0$#9331'"'~'#0$#9331'"$"'?"'3@.2$#0'~'#0$ + #9331'"$"'3@.2$#46655'~'#0$#9331'"'~'#0$ + #9331'"'~'#0$#9331'"$.1 + DO .1 <- :2~#1 + DO :2 <- "'^":1~'#9331$#0'"$":2~'#0$#9330'"' + ~'#0$#9331'"$"'^":1~'#0$#9331'"$":2~'#9331$ + #0'"'~'#0$#9331'" + PLEASE RETRIEVE :1 + .2 + PLEASE RESUME #1 + (1900) DO STASH .2 + .5 + DO .1 <- #0 + DO .2 <- #1 + PLEASE DO (1901) NEXT + (1901) DO FORGET #1 + DO %50 (1904) NEXT + DO %50 (1901) NEXT + PLEASE DO (1903) NEXT + (1904) DO .1 <- '^.1$.2'~'#0$#9331' + DO %50 .1 <- '^.1$.2'~'#0$#9331' + (1903) PLEASE FORGET #1 + DO %50 .1 <- '^.1$".2~#27993"'~'#0$#9331' + DO .2 <- !2$#0'~'#1555$#1' + PLEASE DO .5 <- '^".2~.2"$#1'~#1 + DO (1902) NEXT + DO (1901) NEXT + (1902) DO (1001) NEXT + DO RETRIEVE .2 + .5 + PLEASE RESUME #2 + (1910) PLEASE STASH .1 + .3 + .5 + :1 + :2 + :3 + DO .3 <- #46644 + DO :1 <- #6 + DO (1911) NEXT + PLEASE NOTE THAT YOU CAN'T GET BLOOD FROM A TURNIP + (1912) DO (1001) NEXT + (1911) DO FORGET #1 + PLEASE DO (1900) NEXT + DO :2 <- .1 + DO (1500) NEXT + PLEASE DO :1 <- :3 + DO .1 <- .3 + DO (1020) NEXT + PLEASE DO .3 <- .1 + DO .5 <- '?"!3~.3'~#5"$#4'~#1 + DO (1912) NEXT + DO .1 <- #12 + PLEASE DO (1050) NEXT + DO RETRIEVE .1 + DO (1530) NEXT + DO :2 <- #23328 + DO (1500) NEXT + PLEASE DO .2 <- :3~'#9288$#9288' + PLEASE RETRIEVE .3 + .5 + :1 + :2 + :3 + DO RESUME #1 diff --git a/pit/lib/syslib.7i b/pit/lib/syslib.7i new file mode 100644 index 0000000..1d51a1a --- /dev/null +++ b/pit/lib/syslib.7i @@ -0,0 +1,402 @@ + PLEASE KNOCK "SHAVE-AND-A-HAIRCUT-TWO-PLEASE" BEFORE ENTERING + + (1000) PLEASE IGNORE .4 + PLEASE ABSTAIN FROM (1005) + (1009) DO STASH .1 + .2 + .5 + .6 + DO .4 <- #1 + DO (1004) NEXT + (1004) PLEASE FORGET #1 + DO .3 <- '^.1$.2'~'#0$#2801' + DO .6 <- '?"'V"'V"'&.1$.2'~'#0$#2801'"$"'^"'@.1$ + .2'~'#0$#2801'"$#2801'~'#0$#2801'"'~'#0$ + #2801'"$"'^"'2@.1$.2'~'#0$#2801'"$#5602' + ~'#0$#2801'"'~'#0$#14005'"$#14005'~'#0$#2801' + PLEASE DO .5 <- "?!6~#14406'$#7"~#7 + DO (1002) NEXT + DO .4 <- #2 + (1005) DO (1006) NEXT + (1999) DOUBLE OR SINGLE PRECISION OVERFLOW + (1002) DO (1001) NEXT + (1006) PLEASE FORGET #1 + DO .5 <- '?"!6~.6'~#6"$#7'~#7 + DO (1003) NEXT + DO .1 <- .3 + DO .2 <- !6$#0'~'#400$#1' + DO (1004) NEXT + (1003) DO (1001) NEXT + DO REINSTATE (1005) + (1007) PLEASE RETRIEVE .1 + .2 + .5 + .6 + DO REMEMBER .4 + PLEASE RESUME #2 + (1001) DO RESUME .5 + (1010) DO STASH .1 + .2 + .4 + DO .4 <- .1 + DO .1 <- '?#16806$.2'~'#0$#2801' + DO (1020) NEXT + PLEASE DO .2 <- .4 + PLEASE DO (1009) NEXT + DO RETRIEVE .1 + .2 + .4 + PLEASE RESUME #1 + (1020) DO STASH .2 + .3 + DO .2 <- #1 + PLEASE DO (1021) NEXT + (1021) DO FORGET #1 + DO .3 <- '?"'V".1~.2"$#5'~#1"$#4'~#1 + PLEASE DO .1 <- '^.1$.2'~'#0$#2801' + DO (1022) NEXT + DO .2 <- !2$#0'~'#400$#1' + DO (1021) NEXT + (1023) PLEASE RESUME .3 + (1022) DO (1023) NEXT + PLEASE RETRIEVE .2 + .3 + PLEASE RESUME #2 + (1030) DO ABSTAIN FROM (1033) + PLEASE ABSTAIN FROM (1032) + (1039) DO STASH :1 + .5 + DO (1530) NEXT + DO .3 <- :1~#2801 + PLEASE DO .5 <- :1~'#2793$#2744' + DO .5 <- '?"!5~.5'~#6"$#7'~#7 + DO (1031) NEXT + (1032) DO (1033) NEXT + DO (1999) NEXT + (1031) DO (1001) NEXT + (1033) DO .4 <- .5 + DO REINSTATE (1032) + PLEASE REINSTATE (1033) + DO RETRIEVE :1 + .5 + PLEASE RESUME #2 + (1040) PLEASE STASH .1 + .2 + .2 + :1 + :2 + :3 + DO .2 <- #0 + DO (1520) NEXT + DO STASH :1 + PLEASE RETRIEVE .2 + DO .1 <- .2 + DO .2 <- #0 + PLEASE DO (1520) NEXT + DO :2 <- :1 + DO RETRIEVE .1 + .2 + :1 + DO (1550) NEXT + PLEASE DO .3 <- :3 + DO RETRIEVE :1 + :2 + :3 + DO RESUME #1 + (1050) PLEASE STASH :2 + :3 + .5 + DO :2 <- .1 + PLEASE DO (1550) NEXT + DO .5 <- :3~'#2793$#2744' + DO .5 <- '?"!5~.5'~#6"$#7'~#7 + DO (1051) NEXT + DO (1999) NEXT + (1051) DO (1001) NEXT + DO .2 <- :3 + PLEASE RETRIEVE :2 + :3 + .5 + DO RESUME #2 + (1500) PLEASE ABSTAIN FROM (1502) + PLEASE ABSTAIN FROM (1506) + (1509) PLEASE STASH :1 + .1 + .2 + .3 + .4 + .5 + .6 + DO .1 <- :1~#2801 + PLEASE DO .2 <- :2~#2801 + DO (1009) NEXT + DO .5 <- .3 + PLEASE DO .6 <- .4 + DO .1 <- :1~'#2793$#2744' + DO .2 <- :2~'#2793$#2744' + DO (1009) NEXT + DO .1 <- .3 + PLEASE DO (1503) NEXT + DO .6 <- .4 + DO .2 <- #1 + DO (1009) NEXT + DO .1 <- .3 + DO (1501) NEXT + (1504) PLEASE RESUME .6 + (1503) DO (1504) NEXT + (1501) DO .2 <- .5 + DO .5 <- '&.6$.4' + DO (1505) NEXT + (1506) DO (1502) NEXT + PLEASE DO (1999) NEXT + (1505) DO (1001) NEXT + (1502) DO :4 <- .5 + DO (1520) NEXT + DO :3 <- :1 + PLEASE RETRIEVE :1 + .1 + .2 + .3 + .4 + .5 + .6 + DO REINSTATE (1502) + DO REINSTATE (1506) + PLEASE RESUME #3 + (1510) DO STASH :1 + :2 + :4 + DO :1 <- "'?#16806$":2~'#2801$#0'"'~'#0$#2801'"$ + "'?#16806$":2~'#0$#2801'"'~'#0$#2801'" + DO :2 <- #1 + DO (1509) NEXT + PLEASE RETRIEVE :1 + DO :2 <- :3 + PLEASE DO (1509) NEXT + DO RETRIEVE :2 + :4 + PLEASE RESUME #1 + (1520) PLEASE STASH .3 + .4 + DO .3 <- .1~#2451 + DO (1525) NEXT + PLEASE DO .4 <- 'V.3$".2~#350"'~'#0$#2801' + DO .3 <- .1~#350 + PLEASE DO (1526) NEXT + DO :1 <- .4$"'V.3$".2~#2451"'~'#0$#2801'" + PLEASE RETRIEVE .3 + .4 + DO RESUME #1 + (1525) DO .3 <- '"!3$#0'~'#400$#1'"$#0'~'#400$#1' + PLEASE RESUME #1 + (1526) DO .3 <- '"!3$#0'~'#400$#1'"$#0'~'#57$#8' + PLEASE RESUME #1 + (1530) DO STASH :2 + :3 + :4 + .1 + .2 + .5 + DO :3 <- #0 + DO :4 <- .2 + DO (1535) NEXT + (1535) PLEASE FORGET #1 + DO .5 <- '?".1~#6"$#7'~#7 + DO (1531) NEXT + DO :1 <- :4 + DO (1720) NEXT + DO :1 <- :3 + DO (1500) NEXT + PLEASE DO (1533) NEXT + (1531) PLEASE DO (1001) NEXT + (1533) DO FORGET #1 + DO .1 <- .1~#2800 + DO :4 <- ":4~'#0$#2801'"$"'":4~'#400$#0'"$#0' + ~'#400$#1'" + PLEASE DO .5 <- '?"!1~.1'~#6"$#7'~#7 + DO (1532) NEXT + DO (1535) NEXT + (1532) DO (1001) NEXT + DO :1 <- :3 + PLEASE RETRIEVE :2 + :3 + :4 + .1 + .2 + .5 + DO RESUME #2 + (1540) PLEASE ABSTAIN FROM (1541) + DO ABSTAIN FROM (1542) + (1549) PLEASE STASH :1 + :2 + :4 + :5 + .1 + .2 + .5 + DO .1 <- :1~#2801 + PLEASE DO .2 <- :2~'#2793$#2744' + DO .5 <- :1~'#2793$#2744' + DO (1530) NEXT + DO :3 <- :1 + DO .2 <- :2~#2801 + PLEASE DO (1530) NEXT + DO :5 <- :1 + DO .1 <- .5 + DO (1530) NEXT + DO :4 <- :1 + PLEASE DO :1 <- ":3~'#2793$#2744'"$":4 + ~'#2793$#2744'" + DO .5 <- ':1~:1'~#6 + DO .2 <- :2~'#2793$#2744' + DO (1530) NEXT + PLEASE DO .5 <- '"':1~:1'~#6"$.5'~#8 + DO .1 <- :3~#2801 + DO .2 <- #0 + DO (1520) NEXT + PLEASE DO :2 <- :1 + PLEASE DO .1 <- :4~#2801 + DO (1520) NEXT + DO (1509) NEXT + DO .5 <- !5$"'^":4~#1"$#4'~#1"'~#351 + DO :1 <- :3 + DO :2 <- :5 + DO (1509) NEXT + PLEASE DO .5 <- !5$"'^":4~#1"$#4'~#1"'~'#57$#1' + DO .5 <- '?"!5~.5'~#1"$#4'~#1 + PLEASE RETRIEVE :4 + (1541) DO :4 <- .5 + DO (1543) NEXT + (1542) DO (1544) NEXT + PLEASE DO (1999) NEXT + (1543) DO (1001) NEXT + (1544) DO REINSTATE (1541) + PLEASE REINSTATE (1542) + PLEASE RETRIEVE :1 + :2 + :5 + .1 + .2 + .5 + DO RESUME #2 + (1550) DO STASH :1 + :4 + :5 + :6 + .1 + .5 + DO :5 <- #0 + DO .5 <- '?"':2~:2'~#6"$#7'~#7 + PLEASE DO (1551) NEXT + DO :4 <- #1 + PLEASE DO (1553) NEXT + (1553) DO FORGET #1 + DO .5 <- '?"':2~"#14406$#0"'"$#5'~#1 + DO (1552) NEXT + DO :2 <- ":2~'#0$#2801'"$"'":2~'#400$#0'"$#0' + ~'#400$#1'" + PLEASE DO :4 <- ":4~'#0$#2801'"$"'":4~'#400 + $#0'"$#0'~'#400$#1'" + DO (1553) NEXT + (1552) DO (1001) NEXT + DO .1 <- #0 + (1556) PLEASE FORGET #1 + DO :6 <- "'&":2~'#2801$#0'"$"'?#16806$":1 + ~'#2801$#0'"'~'#0$#2801'"'~'#0$#2801'"$ + "'&":2~'#0$#2801'"$"'?#16806$":1~'#0$ + #2801'"'~'#0$#2801'"'~'#0$#2801'" + DO :3 <- "'?":1~'#2801$#0'"$":2~'#2801$#0'"' + ~'#0$#2801'"$"'?":1~'#0$#2801'"$":2~'#0$ + #2801'"'~'#0$#2801'" + DO :6 <- "'&":6~'#2801$#0'"$":3~'#2801$#0'"' + ~'#0$#2801'"$"'&":6~'#0$#2801'"$":3~'#0$ + #2801'"'~'#0$#2801'" + DO :3 <- :3~'#16806$#16806' + DO :6 <- "'?"'V":6~'#2801$#0'"$#11204'~'#0$ + #2801'"$#11204'~'#0$#16806'"$"'?"'V":6 + ~'#0$#2801'"$#11204'~'#0$#2801'"$#11204' + ~'#0$#16806'" + DO .5 <- "?'"':6~:3'~'"'"'&"':3~:3'~'#2801$#0'"$ + #2401'~'#0$#2801'"$"'?:3~:3'~'#400$#0'"' + ~'#2401$#400'"$"'?:3~:3'~'#0$#2801'"'"~#1'$ + #5"~#1 + PLEASE DO (1557) NEXT + DO (1510) NEXT + DO :1 <- :3 + DO .5 <- '?#0$"'V.1$#5'~#1"'~#1 + DO (1557) NEXT + DO .1 <- '^.1$#2801'~'#0$#2801' + DO (1556) NEXT + (1557) PLEASE DO (1001) NEXT + PLEASE FORGET #1 + DO :5 <- "'V":4~'.1$#0'"$":5~'#2801$#0'"' + ~'#0$#2801'"$"'V":4~'#0$.1'"$":5~'#0$ + #2801'"'~'#0$#2801'" + DO .5 <- "?#2$':4~#1'"~#1 + DO (1551) NEXT + DO :2 <- :2~'#2801$#2800' + DO :4 <- :4~'#2801$#2800' + DO .1 <- #0 + PLEASE DO (1556) NEXT + (1551) DO (1001) NEXT + DO :3 <- :5 + PLEASE RETRIEVE :1 + :4 + :5 + :6 + .1 + .5 + PLEASE RESUME #2 + (1720) PLEASE STASH :1 + :3 + :4 + .1 + .5 + DO :2 <- #0 + DO .2 <- #0 + DO .5 <- '?".1~#6"$#7'~#7 + DO (1729) NEXT + DO .5 <- .1~#1 + DO .2 <- :1~'#2801$#0' + DO .1 <- :1~'#0$#2801' + PLEASE DO (1726) NEXT + DO :1 <- '"?#0$.2"~"#0$#2801"'$'"?#0$.1"~"#0$ + #2801"' + DO :2 <- '"?'"V.2$#2801"~"#0$#2801"'$#2801" + ~"#0$#2801"'$'"?'"V.1$#2801"~"#0$#2801"'$ + #2801"~"#0$#2801"' + DO (1728) NEXT + (1726) PLEASE DO (1725) NEXT + DO :1 <- '"?#0$'"^.2$.2"~"#0$#2801"'"~"#0$ + #2801"'$'"?#0$'"^.1$.1"~"#0$#2801"'"~"#0$ + #2801"' + DO .2 <- "^'"V'"2@.2$#11204"~"#0$#2801"'$ + #5602"~"#0$#2801"'$'"2@.2$#2801"~"#0$ + #2801"'"~"#0$#2801" + DO .1 <- "^'"V'"2@.1$#11204"~"#0$#2801"'$ + #5602"~"#0$#2801"'$'"2@.1$#2801"~"#0$ + #2801"'"~"#0$#2801" + DO :2 <- '"?.2$#8403"~"#0$#2801"'$'"?.1$#8403" + ~"#0$#2801"' + (1728) DO .2 <- :2~'#2401$#0' + DO :2 <- ':2~"#0$#2801"'$'"':2~"#400$#0"'$#0" + ~"#400$#1"' + DO (1509) NEXT + DO :2 <- :3 + DO .2 <- '^.2$"'?":4~#1"$#1'~#1"'~#1 + DO (1721) NEXT + (1725) PLEASE DO (1724) NEXT + DO :2 <- '"?'"V'"?'"3@.2$#14005"~"#0$#2801"'$ + '"@.2$#0"~"#0$#2801"'"~"#0$#11204"'$#8403" + ~"#0$#2801"'$#8403"~"#0$#2801"'$ + '"?'"V'"?'"3@.1$#14005"~"#0$#2801"'$'"@.1$ + #0"~"#0$#2801"'"~"#0$#11204"'$#8403"~"#0$ + #2801"'$#8403"~"#0$#2801"' + DO .2 <- '^.2$.2'~'#0$#2801' + DO .1 <- '^.1$.1'~'#0$#2801' + DO :1 <- '"^.2$.2"~"#0$#2801"'$'"^.1$.1"~"#0$ + #2801"' + PLEASE FORGET #2 + DO (1728) NEXT + (1724) PLEASE DO (1723) NEXT + DO :1 <- '"^'"^.2$.2"~"#0$#2801"'$.2"~"#0$ + #2801"'$'"^'"^.1$.1"~"#0$#2801"'$.1" + ~"#0$#2801"' + DO .2 <- "^'"V'"2@.2$#16806"~"#0$#2801"'$ + #14005"~"#0$#2801"'$'"V'"4@.2$#16806" + ~"#0$#2801"'$#14005"~"#0$#2801"'"~"#0$ + #2801" + DO .1 <- "^'"V'"2@.1$#16806"~"#0$#2801"'$ + #14005"~"#0$#2801"'$'"V'"4@.1$#16806" + ~"#0$#2801"'$#14005"~"#0$#2801"'"~"#0$ + #2801" + DO :2 <- '"?.2$#8403"~"#0$#2801"'$'"?.1$#8403" + ~"#0$#2801"' + PLEASE FORGET #3 + DO (1728) NEXT + (1723) PLEASE DO (1722) NEXT + DO :1 <- '"^.2$.2"~"#0$#2801"'$'"^.1$.1"~"#0$ + #2801"' + DO :2 <- '"?'"V'"3@.2$#16806"~"#0$#2801"'$ + #14005"~"#0$#2801"'$#14005"~"#0$#2801"'$ + '"?'"V'"3@.1$#16806"~"#0$#2801"'$#14005" + ~"#0$#2801"'$#14005"~"#0$#2801"' + PLEASE FORGET #4 + DO (1728) NEXT + (1729) DO (1001) NEXT + DO (1721) NEXT + (1722) PLEASE DO (1001) NEXT + DO :2 <- :1 + DO .2 <- #0 + DO FORGET #3 + (1721) PLEASE RETRIEVE :1 + :3 + :4 + .1 + .5 + PLEASE RESUME #3 + (1900) DO STASH .2 + .5 + DO .1 <- #0 + DO .2 <- #1 + PLEASE DO (1901) NEXT + (1901) DO FORGET #1 + DO %50 (1905) NEXT + DO %50 (1904) NEXT + DO %50 (1901) NEXT + PLEASE DO (1903) NEXT + (1905) DO FORGET #1 + DO .1 <- '^.1$".2~#8403"'~'#0$#2801' + PLEASE DO %50 .1 <- '^.1$".2~#5602"'~'#0$#2801' + DO (1906) NEXT + (1904) DO .1 <- '^.1$.2'~'#0$#2801' + (1906) DO %50 .1 <- '^.1$.2'~'#0$#2801' + (1903) PLEASE FORGET #1 + DO .2 <- !2$#0'~'#400$#1' + PLEASE DO .5 <- '^".2~.2"$#1'~#1 + DO (1902) NEXT + DO (1901) NEXT + (1902) DO (1001) NEXT + DO RETRIEVE .2 + .5 + PLEASE RESUME #2 + (1910) PLEASE STASH .1 + .3 + .5 + :1 + :2 + :3 + DO .3 <- #16795 + DO :1 <- #6 + DO (1911) NEXT + PLEASE NOTE THAT YOU CAN'T GET SENSE FROM INTERCAL + (1912) DO (1001) NEXT + (1911) DO FORGET #1 + PLEASE DO (1900) NEXT + DO :2 <- .1 + DO (1500) NEXT + PLEASE DO :1 <- :3 + DO .1 <- .3 + DO (1020) NEXT + PLEASE DO .3 <- .1 + DO .5 <- '?"!3~.3'~#6"$#5'~#1 + DO (1912) NEXT + DO .1 <- #12 + PLEASE DO (1050) NEXT + DO RETRIEVE .1 + DO (1530) NEXT + DO :2 <- #8403 + DO (1500) NEXT + PLEASE DO .2 <- :3~'#2793$#2744' + PLEASE RETRIEVE .3 + .5 + :1 + :2 + :3 + DO RESUME #1 diff --git a/pit/lib/syslib.doc b/pit/lib/syslib.doc new file mode 100644 index 0000000..e8e637d --- /dev/null +++ b/pit/lib/syslib.doc @@ -0,0 +1,103 @@ + +The file syslib_old.i is the version of the system library included +in the original manual. RTFM for descriptions of the routines. Only +minimal changes have been made in the current version, as follows: + +1. Someone added + PLEASE KNOCK BEFORE ENTERING +as the first line, presumably to prevent programs from running off the +end and into the first library routine by mistake. + +The other two changes are bug fixes. The bugs appear in all copies of +the library that I have, including the manual from Don Woods (via Mike +Ernst) with carriage controls in the first column. Unless a still more +ancient copy of the library can be found (like in the Dead Sea Scrolls, +perhaps?) we have to assume these bugs have been in there from the +beginning, or at least since the library was converted from EBCDIC to +ASCII and incorporated into the manual. + +2. Jacob Mandelson found a bug in the 32-bit division routine where a +select (~) had been substituted for a mingle ($) by mistake. This is at +the end of line 229 of syslib_old.i. I have not checked or tested this +correction, but it seems reasonable since select at that position would +be pointless, but mingle is plausible. + +3. I have found either two or three bugs in the 32-bit multiplication +routines, depending on how you count. These only affected the overflow +checking, but the effect was that every single call to (1540) or (1549) +would behave as if there were an overflow. + +The first is straightforward. The statement + PLEASE DO :1 <- ":3~'#65280$#65280'"$":5~'#652 + 80$#65280'" +must be changed to + PLEASE DO :1 <- ":3~'#65280$#65280'"$":4~'#652 + 80$#65280'" +Not only is this the "right thing to do", but the position of this +statement just after :4 has been computed suggests that it was what +the original author intended. + +The remaining problems, however, are not so clearly due to typos. The +32-bit multiplication is done by splitting each input into its low and +high 16-bit halves, computing partial products with the (1530) 16 to +32-bit multiplication routine, and then adding them together using +(1509), addition with overflow check. The statements to look at are +the ones where the overflow flags from successive steps are accumulated +in .5, as follows: + + [a] DO .5 <- ':1~:1'~#1 + ... + + [b] PLEASE DO .5 <- '"':1~:1'~#1"$.5'~#3 + ... + + DO (1509) NEXT + [c] DO .5 <- !5$":4~#3"'~#15 + ... + + DO (1509) NEXT + [d] PLEASE DO .5 <- !5$":4~#3"'~#63 + DO .5 <- '?"!5~.5'~#1"$#1'~#3 + +.5 gets a bit if the high-high product is nonzero (wasteful to even compute +this product, actually), and another if either of the high-low products +overflows (that's the statement with the previous bug, above). It then +gets combined with the overflow flags in :4 from the two addition calls. +Each new flag is mingled with the ones already in .5, so various bits of +.5 correspond to the different possible overflows. Finally, .5 is tested +to see if it is nonzero, and if so an overflow results. + +Note the expressions ":4~#3". :4 is returned by (1509) as #2 if there is +an overflow, #1 if not. It either case a bit is set in .5. This is why +the routines signaled an overflow every time. Note also the ~#63 in line +[d]. At this point the bit representing existence of the high-high +product has shifted out to the 128-bit, so ~#63 will miss it. + +I see three ways out, none of which are obviously the author's intent: + + (1) At statement [d] the bit pattern is 101011XX, where 1's indicate + overflows and X's are set by (1509) without overflow. If we replace + ~#63 with ~#172 we test exactly the bits we want. This is the one + I've used since it is the minimal change. + + (2) If we replace ":4~#3" with ":4~#2" we only have bits set on overflow, + which seems cleaner. The bit pattern is 10001011 so we still can't use + ~#63, we have to use ~#139 or ~#255 or something similar to get all the + bits. Actually, the final selects in lines [b], [c] and [d] are all + superfluous in this case since the bits discarded are all zero and the + selected quantity can be safely assigned to the 16-bit .5. + + (3) If we replace ":4~#3" with ":4~#2" and reverse the mingles to look + like '":4~#2"$.5' then the final bit pattern is 10111 and ~#63 will work, + though it is not necessary. + +There are other solutions, of course, but I don't see any simpler ones +than these. If you think ":4~#3" accomplishes nothing, so ":4~#2" must be +meant, note that ":4~#3" converts :4 to 16-bit. The original compiler +apparently required arguments to mingle to be 16-bit, whereas I think +the C-INTERCAL compiler only requires them to be less than #0$#256. +":4$.5" would thus be technically illegal, even though it might work in +C-INTERCAL. + + Louis Howell + May 25, 1996 diff --git a/pit/lib/syslib.i b/pit/lib/syslib.i index 1a3189f..ace68f7 100644 --- a/pit/lib/syslib.i +++ b/pit/lib/syslib.i @@ -122,9 +122,8 @@ DO REINSTATE (1506) PLEASE RESUME #3 (1510) DO STASH :1 + :2 + :4 - DO :1 <- "'?":2~'#65535$#0'"$#65535'~'#0$#6553 - 5'"$"'?":2~'#0$#65535'"$#65535'~'#0$#65535 - '" + DO :1 <- "'?":2~'#65535$#0'"$#65535'~'#0$#65535'"$ + "'?":2~'#0$#65535'"$#65535'~'#0$#65535'" DO :2 <- #1 DO (1509) NEXT PLEASE RETRIEVE :1 @@ -141,8 +140,8 @@ DO :1 <- .4$"'V.3$".2~#21845"'~'#0$#65535'" PLEASE RETRIEVE .3 + .4 DO RESUME #1 - (1525) DO .3 <- '"'"'"!3$#0'~'#32767$#1'"$#0'~'#32767 - $#1'"$#0'~'#16383$#3'"$#0'~'#4095$#15' + (1525) DO .3 <- '"'"'"!3$#0'~'#32767$#1'"$#0'~'#32767$ + #1'"$#0'~'#16383$#3'"$#0'~'#4095$#15' PLEASE RESUME #1 (1530) DO STASH :2 + :3 + .3 + .5 DO :1 <- #0 @@ -158,8 +157,8 @@ (1531) PLEASE DO (1001) NEXT (1533) DO FORGET #1 DO .3 <- !3$#0'~'#32767$#1' - DO :2 <- ":2~'#0$#65535'"$"'":2~'#32767$#0'"$# - 0'~'#32767$#1'" + DO :2 <- ":2~'#0$#65535'"$"'":2~'#32767$#0'"$ + #0'~'#32767$#1'" PLEASE DO .5 <- "?!3~.3'$#1"~#3 DO (1532) NEXT DO (1535) NEXT @@ -180,8 +179,8 @@ DO .1 <- .5 DO (1530) NEXT DO :4 <- :1 - PLEASE DO :1 <- ":3~'#65280$#65280'"$":4~'#652 - 80$#65280'" + PLEASE DO :1 <- ":3~'#65280$#65280'"$":4~'#65280$ + #65280'" DO .5 <- ':1~:1'~#1 DO .2 <- :2~'#65280$#65280' DO (1530) NEXT @@ -219,7 +218,7 @@ DO .5 <- '?":2~'#32768$#0'"$#2'~#3 DO (1552) NEXT DO :2 <- ":2~'#0$#65535'"$"'":2~'#32767$#0'"$# - 0'~'#32767$#1'" + 0'~'#32767$#1'" PLEASE DO :4 <- ":4~'#0$#65535'"$"'":4~'#32767 $#0'"$#0'~'#32767$#1'" DO (1553) NEXT diff --git a/pit/lib/syslib3-7.doc b/pit/lib/syslib3-7.doc new file mode 100644 index 0000000..f3a372d --- /dev/null +++ b/pit/lib/syslib3-7.doc @@ -0,0 +1,53 @@ +Although the non-binary libraries syslib.[3-7]i are meant to be +treated as workalikes with the original system library, it should be +noted that several of them contain some new routines. These are used +internally by the standard routines, and are there to provide methods +for doing a few things that are taken for granted in base 2. While +they were not intended to be used by other programs, there is nothing +stopping them from being so used. + +The even bases have routines to double and halve values, and use a +third variable as a carry/borrow flag. Since halving in odd bases +produces infinite fractions, bases 5 and 7 instead use a single-digit +multiplication routine. (Base 3 multiplication is still simple enough +to be handled without a separate support routine.) + +syslib.4i +--------- +(1200) .2 <- .1 times two + .3 <- #0 if no overflow, otherwise .3 contains the quart that + was "shifted" off the left end +(1210) .2 <- .1 divided by two + .3 <- #0 if .1 is even, otherwise .3 contains #2 +(1700) :2 <- :1 times two + .1 <- #0 if no overflow, otherwise .1 contains the quart that + was "shifted" off the left end +(1710) :2 <- :1 divided by two + .1 <- #0 if .1 is even, otherwise .1 contains #2 + +syslib.5i +--------- +(1720) :2 <- :1 times the least significant quint of .1 (the remaining + quints of .1 are ignored) + .2 <- #0 if no overflow, otherwise .2 contains the quint that + was "shifted" off the left end + +syslib.6i +--------- +(1200) .2 <- .1 times two + .3 <- #0 if no overflow, otherwise .3 contains the sext that + was "shifted" off the left end +(1210) .2 <- .1 divided by two + .3 <- #0 if .1 is even, otherwise .3 contains #3 +(1700) :2 <- :1 times two + .1 <- #0 if no overflow, otherwise .1 contains the sext that + was "shifted" off the left end +(1710) :2 <- :1 divided by two + .1 <- #0 if .1 is even, otherwise .1 contains #3 + +syslib.7i +--------- +(1720) :2 <- :1 times the least significant sept of .1 (the remaining + septs of .1 are ignored) + .2 <- #0 if no overflow, otherwise .2 contains the sept that + was "shifted" off the left end diff --git a/pit/life.doc b/pit/life.doc index 50c4316..494886e 100644 --- a/pit/life.doc +++ b/pit/life.doc @@ -13,10 +13,9 @@ the file. ----------------------------------------------------------------------------- -Article: 115 of alt.lang.intercal -From: howell@grover.llnl.gov (Louis Howell) -Newsgroups: alt.lang.intercal Subject: Life with Intercal (long) +Newsgroups: alt.lang.intercal +From: Louis Howell Date: Mon, 28 Jan 91 09:17:36 PST I suppose some of you are wondering if anyone ever actually writes anything diff --git a/pit/life2.i b/pit/life2.i index 4c800ba..8c8f00d 100644 --- a/pit/life2.i +++ b/pit/life2.i @@ -230,7 +230,7 @@ PLEASE FORGET #3 (316) DO .6 <- .1 (314) DO (315) NEXT - DO PLEASE STASH .2 + PLEASE DO STASH .2 PLEASE RESUME #3 (500) DO (501) NEXT diff --git a/pit/pi.doc b/pit/pi.doc index a5244c1..33b017e 100644 --- a/pit/pi.doc +++ b/pit/pi.doc @@ -1,24 +1,3 @@ -From howell@grover.llnl.gov (Louis Howell) Fri Jan 3 12:31:20 1992 -From: howell@grover.llnl.gov (Louis Howell) -Path: snark!cbmvax!uunet!uunet!spool.mu.edu!agate!bionet!raven.alaska.edu!lll-winken!grover.llnl.gov!howell -Newsgroups: alt.lang.intercal -Subject: pi.doc -Message-ID: <114696@lll-winken.LLNL.GOV> -Date: 3 Jan 92 17:31:20 GMT -Date-Received: 4 Jan 92 11:08:10 GMT -Sender: usenet@lll-winken.LLNL.GOV -Distribution: world -Organization: Lawrence Livermore National Laboratory -Nntp-Posting-Host: grover.llnl.gov -Lines: 91 - -Those of you who've bothered to actually run the "mystery program" I -posted last week will have realized that it prints out digits of pi. -If you didn't get it, never fear. Eric is putting it into his new -0.8 release, which he is eager to finish soon. The program is pi.i, -and the stuff below this line is pi.doc: - ---------------- pi.i is easily the most twisted and obscure INTERCAL program I've yet written. I say that because even I don't fully understand why it @@ -103,5 +82,3 @@ char *argv[]; } printf("\n"); } - - diff --git a/pit/quine.i b/pit/quine.i new file mode 100644 index 0000000..3bc2452 --- /dev/null +++ b/pit/quine.i @@ -0,0 +1,649 @@ + DO (1) NEXT + DO ;1SUB#1 <- #46164$#24148 + DO ;1SUB#2 <- #49728$#63680 + PLEASE ;1SUB#3 <- #50560$#9536 + DO ;1SUB#4 <- #23200$#11688 + DO ;1SUB#5 <- #63912$#51392 + DO ;1SUB#6 <- #57536$#39424 + PLEASE ;1SUB#7 <- #54224$#46164 + DO ;1SUB#8 <- #24148$#28936 + DO ;1SUB#9 <- #8448$#50860 + DO ;1SUB#10 <- #5056$#25684 + PLEASE ;1SUB#11 <- #48704$#4752 + DO ;1SUB#12 <- #46164$#24148 + DO ;1SUB#13 <- #53824$#55488 + DO ;1SUB#14 <- #50560$#23616 + PLEASE ;1SUB#15 <- #56960$#59968 + DO ;1SUB#16 <- #28140$#60096 + DO ;1SUB#17 <- #7168$#20160 + DO ;1SUB#18 <- #28012$#49104 + PLEASE ;1SUB#19 <- #46164$#24148 + DO ;1SUB#20 <- #64064$#52096 + DO ;1SUB#21 <- #54024$#54656 + DO ;1SUB#22 <- #62088$#11688 + PLEASE ;1SUB#23 <- #60648$#57920 + DO ;1SUB#24 <- #57536$#39424 + DO ;1SUB#25 <- #21120$#7168 + DO ;1SUB#26 <- #8256$#10560 + PLEASE ;1SUB#27 <- #54016$#3072 + DO ;1SUB#28 <- #55968$#11688 + DO ;1SUB#29 <- #64936$#6592 + DO ;1SUB#30 <- #49924$#57920 + PLEASE ;1SUB#31 <- #64324$#46164 + DO ;1SUB#32 <- #24148$#55680 + DO ;1SUB#33 <- #53440$#50560 + DO ;1SUB#34 <- #9536$#61184 + PLEASE ;1SUB#35 <- #16384$#13440 + DO ;1SUB#36 <- #11904$#15360 + DO ;1SUB#37 <- #21152$#11688 + DO ;1SUB#38 <- #64936$#9664 + PLEASE ;1SUB#39 <- #49924$#57920 + DO ;1SUB#40 <- #64324$#23264 + DO ;1SUB#41 <- #35472$#11688 + DO ;1SUB#42 <- #64936$#49280 + PLEASE ;1SUB#43 <- #16384$#60288 + DO ;1SUB#44 <- #54024$#54656 + DO ;1SUB#45 <- #62088$#11688 + DO ;1SUB#46 <- #60648$#57920 + PLEASE ;1SUB#47 <- #57536$#39424 + DO ;1SUB#48 <- #53888$#44032 + DO ;1SUB#49 <- #8256$#31040 + DO ;1SUB#50 <- #37120$#64336 + PLEASE ;1SUB#51 <- #6880$#2704 + DO ;1SUB#52 <- #11688$#60588 + DO ;1SUB#53 <- #28224$#14464 + DO ;1SUB#54 <- #11924$#9536 + PLEASE ;1SUB#55 <- #23200$#11688 + DO ;1SUB#56 <- #64936$#6592 + DO ;1SUB#57 <- #49924$#57920 + DO ;1SUB#58 <- #64324$#46164 + PLEASE ;1SUB#59 <- #24148$#55680 + DO ;1SUB#60 <- #53440$#50560 + DO ;1SUB#61 <- #30016$#20224 + DO ;1SUB#62 <- #14336$#7296 + PLEASE ;1SUB#63 <- #50816$#43520 + DO ;1SUB#64 <- #30544$#46164 + DO ;1SUB#65 <- #24148$#44608 + DO ;1SUB#66 <- #25472$#54024 + PLEASE ;1SUB#67 <- #54656$#62088 + DO ;1SUB#68 <- #11688$#59816 + DO ;1SUB#69 <- #5312$#57536 + DO ;1SUB#70 <- #39424$#20096 + PLEASE ;1SUB#71 <- #60752$#46164 + DO ;1SUB#72 <- #24148$#34368 + DO ;1SUB#73 <- #28864$#50560 + DO ;1SUB#74 <- #12608$#336 + PLEASE ;1SUB#75 <- #46164$#24148 + DO ;1SUB#76 <- #60992$#58240 + DO ;1SUB#77 <- #54024$#54656 + DO ;1SUB#78 <- #62088$#11688 + PLEASE ;1SUB#79 <- #59816$#59584 + DO ;1SUB#80 <- #57536$#51968 + DO ;1SUB#81 <- #49616$#46164 + DO ;1SUB#82 <- #24148$#48960 + PLEASE ;1SUB#83 <- #16768$#54024 + DO ;1SUB#84 <- #54656$#62088 + DO ;1SUB#85 <- #11688$#59816 + DO ;1SUB#86 <- #6336$#57536 + PLEASE ;1SUB#87 <- #39424$#54224 + DO ;1SUB#88 <- #46164$#24148 + DO ;1SUB#89 <- #60992$#58240 + DO ;1SUB#90 <- #54024$#54656 + PLEASE ;1SUB#91 <- #62088$#11688 + DO ;1SUB#92 <- #60648$#57920 + DO ;1SUB#93 <- #57536$#39424 + DO ;1SUB#94 <- #21120$#29696 + PLEASE ;1SUB#95 <- #14400$#32064 + DO ;1SUB#96 <- #7936$#44032 + DO ;1SUB#97 <- #62112$#11688 + DO ;1SUB#98 <- #64936$#6592 + PLEASE ;1SUB#99 <- #49924$#57920 + DO ;1SUB#100 <- #64324$#46164 + DO ;1SUB#101 <- #24148$#33344 + DO ;1SUB#102 <- #30912$#50560 + PLEASE ;1SUB#103 <- #9536$#44800 + DO ;1SUB#104 <- #21152$#11688 + DO ;1SUB#105 <- #59816$#59584 + DO ;1SUB#106 <- #57536$#36352 + PLEASE ;1SUB#107 <- #4480$#41992 + DO ;1SUB#108 <- #30932$#32960 + DO ;1SUB#109 <- #26988$#6464 + DO ;1SUB#110 <- #40960$#44032 + PLEASE ;1SUB#111 <- #38016$#36544 + DO ;1SUB#112 <- #53792$#11688 + DO ;1SUB#113 <- #64936$#27520 + DO ;1SUB#114 <- #27520$#54024 + PLEASE ;1SUB#115 <- #54656$#62088 + DO ;1SUB#116 <- #11688$#59816 + DO ;1SUB#117 <- #6336$#57536 + DO ;1SUB#118 <- #39424$#48768 + PLEASE ;1SUB#119 <- #21152$#11688 + DO ;1SUB#120 <- #64936$#55744 + DO ;1SUB#121 <- #49924$#57920 + DO ;1SUB#122 <- #64324$#46164 + PLEASE ;1SUB#123 <- #24148$#54848 + DO ;1SUB#124 <- #53440$#50560 + DO ;1SUB#125 <- #2112$#29188 + DO ;1SUB#126 <- #7232$#57576 + PLEASE ;1SUB#127 <- #5268$#34440 + DO ;1SUB#128 <- #57024$#14656 + DO ;1SUB#129 <- #40960$#44032 + DO ;1SUB#130 <- #57744$#46164 + PLEASE ;1SUB#131 <- #24148$#48960 + DO ;1SUB#132 <- #16768$#54024 + DO ;1SUB#133 <- #54656$#62088 + DO ;1SUB#134 <- #11688$#59816 + PLEASE ;1SUB#135 <- #6336$#57536 + DO ;1SUB#136 <- #39424$#35200 + DO ;1SUB#137 <- #55968$#11688 + DO ;1SUB#138 <- #64936$#55744 + PLEASE ;1SUB#139 <- #49924$#57920 + DO ;1SUB#140 <- #64324$#46164 + DO ;1SUB#141 <- #24148$#53824 + DO ;1SUB#142 <- #55488$#50560 + PLEASE ;1SUB#143 <- #45120$#18048 + DO ;1SUB#144 <- #37184$#40960 + DO ;1SUB#145 <- #44032$#18924 + DO ;1SUB#146 <- #38976$#49344 + PLEASE ;1SUB#147 <- #58496$#43476 + DO ;1SUB#148 <- #39880$#40960 + DO ;1SUB#149 <- #59392$#27776 + DO ;1SUB#150 <- #42348$#50496 + PLEASE ;1SUB#151 <- #48256$#29312 + DO ;1SUB#152 <- #21504$#7232 + DO ;1SUB#153 <- #27648$#58732 + DO ;1SUB#154 <- #20160$#46080 + PLEASE ;1SUB#155 <- #6848$#58732 + DO ;1SUB#156 <- #49104$#46164 + DO ;1SUB#157 <- #24148$#65088 + DO ;1SUB#158 <- #50048$#54024 + PLEASE ;1SUB#159 <- #54656$#62088 + DO ;1SUB#160 <- #11688$#59816 + DO ;1SUB#161 <- #59584$#57536 + DO ;1SUB#162 <- #51968$#49616 + PLEASE ;1SUB#163 <- #46164$#24148 + DO ;1SUB#164 <- #59968$#53248 + DO ;1SUB#165 <- #13632$#49924 + DO ;1SUB#166 <- #57920$#64324 + PLEASE ;1SUB#167 <- #7904$#656 + DO ;1SUB#168 <- #11688$#59816 + DO ;1SUB#169 <- #54464$#57536 + DO ;1SUB#170 <- #51968$#44496 + PLEASE ;1SUB#171 <- #24288$#33424 + DO ;1SUB#172 <- #11688$#64936 + DO ;1SUB#173 <- #49280$#16384 + DO ;1SUB#174 <- #60288$#54024 + PLEASE ;1SUB#175 <- #54656$#62088 + DO ;1SUB#176 <- #11688$#60588 + DO ;1SUB#177 <- #28224$#14464 + DO ;1SUB#178 <- #11924$#9536 + PLEASE ;1SUB#179 <- #23200$#11688 + DO ;1SUB#180 <- #64936$#60096 + DO ;1SUB#181 <- #49924$#57920 + DO ;1SUB#182 <- #64324$#46164 + PLEASE ;1SUB#183 <- #24148$#52936 + DO ;1SUB#184 <- #7168$#940 + DO ;1SUB#185 <- #24704$#22824 + DO ;1SUB#186 <- #36304$#46164 + PLEASE ;1SUB#187 <- #24148$#6408 + DO ;1SUB#188 <- #22720$#37868 + DO ;1SUB#189 <- #52548$#1360 + DO ;1SUB#190 <- #54720$#5236 + PLEASE ;1SUB#191 <- #24148$#33344 + DO ;1SUB#192 <- #30912$#50560 + DO ;1SUB#193 <- #13632$#45056 + DO ;1SUB#194 <- #25936$#46164 + PLEASE ;1SUB#195 <- #24148$#6528 + DO ;1SUB#196 <- #53440$#50560 + DO ;1SUB#197 <- #33344$#60908 + DO ;1SUB#198 <- #29312$#21504 + PLEASE ;1SUB#199 <- #54608$#46164 + DO ;1SUB#200 <- #24148$#6528 + DO ;1SUB#201 <- #41992$#15828 + DO ;1SUB#202 <- #19136$#57536 + PLEASE ;1SUB#203 <- #39424$#24192 + DO ;1SUB#204 <- #22272$#12352 + DO ;1SUB#205 <- #15680$#19456 + DO ;1SUB#206 <- #10496$#61600 + PLEASE ;1SUB#207 <- #11688$#44264 + DO ;1SUB#208 <- #29188$#7232 + DO ;1SUB#209 <- #16360$#28864 + DO ;1SUB#210 <- #50560$#8512 + PLEASE ;1SUB#211 <- #512$#6912 + DO ;1SUB#212 <- #48768$#13952 + DO ;1SUB#213 <- #42240$#20560 + DO ;1SUB#214 <- #46164$#24148 + PLEASE ;1SUB#215 <- #6528$#41992 + DO ;1SUB#216 <- #15828$#64192 + DO ;1SUB#217 <- #57536$#39424 + DO ;1SUB#218 <- #17024$#22528 + PLEASE ;1SUB#219 <- #2112$#10560 + DO ;1SUB#220 <- #53248$#45056 + DO ;1SUB#221 <- #21152$#11688 + DO ;1SUB#222 <- #59816$#58304 + PLEASE ;1SUB#223 <- #57536$#39424 + DO ;1SUB#224 <- #6784$#64160 + DO ;1SUB#225 <- #11688$#64936 + DO ;1SUB#226 <- #60096$#49924 + PLEASE ;1SUB#227 <- #57920$#64324 + DO ;1SUB#228 <- #46164$#24148 + DO ;1SUB#229 <- #54080$#53952 + DO ;1SUB#230 <- #50560$#33344 + PLEASE ;1SUB#231 <- #21152$#11688 + DO ;1SUB#232 <- #63912$#46272 + DO ;1SUB#233 <- #57536$#39424 + DO ;1SUB#234 <- #4048$#46164 + PLEASE ;1SUB#235 <- #24148$#62016 + DO ;1SUB#236 <- #35848$#15828 + DO ;1SUB#237 <- #19136$#57536 + DO ;1SUB#238 <- #39424$#31360 + PLEASE ;1SUB#239 <- #31312$#46164 + DO ;1SUB#240 <- #24148$#52936 + DO ;1SUB#241 <- #7168$#940 + DO ;1SUB#242 <- #24704$#22824 + PLEASE ;1SUB#243 <- #51392$#23296 + DO ;1SUB#244 <- #62016$#21152 + DO ;1SUB#245 <- #11688$#59816 + DO ;1SUB#246 <- #5312$#57536 + PLEASE ;1SUB#247 <- #39424$#35200 + DO ;1SUB#248 <- #55968$#11688 + DO ;1SUB#249 <- #60908$#55744 + DO ;1SUB#250 <- #23872$#17236 + PLEASE ;1SUB#251 <- #9536$#2720 + DO ;1SUB#252 <- #20192$#41616 + DO ;1SUB#253 <- #11688$#44524 + DO ;1SUB#254 <- #52288$#53184 + PLEASE ;1SUB#255 <- #16808$#59584 + DO ;1SUB#256 <- #23296$#50752 + DO ;1SUB#257 <- #31392$#11688 + DO ;1SUB#258 <- #59816$#59584 + PLEASE ;1SUB#259 <- #57536$#51968 + DO ;1SUB#260 <- #464$#46164 + DO ;1SUB#261 <- #24148$#59968 + DO ;1SUB#262 <- #49152$#38208 + PLEASE ;1SUB#263 <- #49924$#57920 + DO ;1SUB#264 <- #64324$#46164 + DO ;1SUB#265 <- #24148$#62016 + DO ;1SUB#266 <- #35848$#15828 + PLEASE ;1SUB#267 <- #19136$#57536 + DO ;1SUB#268 <- #51968$#39124 + DO ;1SUB#269 <- #40904$#34816 + DO ;1SUB#270 <- #29344$#11688 + PLEASE ;1SUB#271 <- #60908$#35968 + DO ;1SUB#272 <- #10580$#4680 + DO ;1SUB#273 <- #33812$#62016 + DO ;1SUB#274 <- #21152$#11688 + PLEASE ;1SUB#275 <- #59816$#5312 + DO ;1SUB#276 <- #57536$#51968 + DO ;1SUB#277 <- #24016$#46164 + DO ;1SUB#278 <- #24148$#52936 + PLEASE ;1SUB#279 <- #32384$#57216 + DO ;1SUB#280 <- #23232$#50088 + DO ;1SUB#281 <- #59584$#23296 + DO ;1SUB#282 <- #50752$#31392 + PLEASE ;1SUB#283 <- #11688$#60908 + DO ;1SUB#284 <- #55744$#23872 + DO ;1SUB#285 <- #17236$#9536 + DO ;1SUB#286 <- #2720$#3808 + PLEASE ;1SUB#287 <- #8848$#11688 + DO ;1SUB#288 <- #63912$#55428 + DO ;1SUB#289 <- #7232$#12264 + DO ;1SUB#290 <- #53440$#50560 + PLEASE ;1SUB#291 <- #55680$#16876 + DO ;1SUB#292 <- #18752$#15360 + DO ;1SUB#293 <- #58112$#48256 + DO ;1SUB#294 <- #36544$#53792 + PLEASE ;1SUB#295 <- #11688$#63912 + DO ;1SUB#296 <- #55428$#7232 + DO ;1SUB#297 <- #16360$#28864 + DO ;1SUB#298 <- #50560$#55680 + PLEASE ;1SUB#299 <- #16876$#7488 + DO ;1SUB#300 <- #46336$#59904 + DO ;1SUB#301 <- #38016$#36544 + DO ;1SUB#302 <- #53792$#11688 + PLEASE ;1SUB#303 <- #63912$#55428 + DO ;1SUB#304 <- #7232$#32744 + DO ;1SUB#305 <- #61632$#50560 + DO ;1SUB#306 <- #55680$#16876 + PLEASE ;1SUB#307 <- #19776$#48256 + DO ;1SUB#308 <- #38528$#30976 + DO ;1SUB#309 <- #34368$#53792 + DO ;1SUB#310 <- #11688$#63912 + PLEASE ;1SUB#311 <- #55428$#7232 + DO ;1SUB#312 <- #27624$#22720 + DO ;1SUB#313 <- #50560$#55680 + DO ;1SUB#314 <- #16876$#19776 + PLEASE ;1SUB#315 <- #48256$#31360 + DO ;1SUB#316 <- #32512$#53312 + DO ;1SUB#317 <- #53792$#11688 + DO ;1SUB#318 <- #60908$#35968 + PLEASE ;1SUB#319 <- #10580$#4680 + DO ;1SUB#320 <- #33812$#58944 + DO ;1SUB#321 <- #23200$#11688 + DO ;1SUB#322 <- #60908$#55744 + PLEASE ;1SUB#323 <- #23872$#17236 + DO ;1SUB#324 <- #9536$#2720 + DO ;1SUB#325 <- #24544$#32912 + DO ;1SUB#326 <- #11688$#63912 + PLEASE ;1SUB#327 <- #51392$#57536 + DO ;1SUB#328 <- #51968$#45776 + DO ;1SUB#329 <- #46164$#24148 + DO ;1SUB#330 <- #54848$#53440 + PLEASE ;1SUB#331 <- #50560$#25920 + DO ;1SUB#332 <- #55968$#11688 + DO ;1SUB#333 <- #47276$#45568 + DO ;1SUB#334 <- #17236$#35144 + PLEASE ;1SUB#335 <- #12928$#56744 + DO ;1SUB#336 <- #60288$#47760 + DO ;1SUB#337 <- #46164$#24148 + DO ;1SUB#338 <- #59968$#53248 + PLEASE ;1SUB#339 <- #13632$#49924 + DO ;1SUB#340 <- #57920$#64324 + DO ;1SUB#341 <- #46164$#24148 + DO ;1SUB#342 <- #37440$#22720 + PLEASE ;1SUB#343 <- #50560$#54848 + DO ;1SUB#344 <- #23200$#11688 + DO ;1SUB#345 <- #64936$#49280 + DO ;1SUB#346 <- #45056$#27520 + PLEASE ;1SUB#347 <- #54024$#54656 + DO ;1SUB#348 <- #62088$#11688 + DO ;1SUB#349 <- #59816$#55488 + DO ;1SUB#350 <- #57536$#51968 + PLEASE ;1SUB#351 <- #44496$#46164 + DO ;1SUB#352 <- #24148$#59968 + DO ;1SUB#353 <- #53248$#13632 + DO ;1SUB#354 <- #49924$#57920 + PLEASE ;1SUB#355 <- #64324$#46164 + DO ;1SUB#356 <- #24148$#34368 + DO ;1SUB#357 <- #28864$#50560 + DO ;1SUB#358 <- #54848$#23200 + PLEASE ;1SUB#359 <- #11688$#64936 + DO ;1SUB#360 <- #49280$#45056 + DO ;1SUB#361 <- #27520$#54024 + DO ;1SUB#362 <- #54656$#62088 + PLEASE ;1SUB#363 <- #11688$#60648 + DO ;1SUB#364 <- #57920$#57536 + DO ;1SUB#365 <- #36416$#29188 + DO ;1SUB#366 <- #7232$#57320 + PLEASE ;1SUB#367 <- #17900$#29312 + DO ;1SUB#368 <- #21504$#37952 + DO ;1SUB#369 <- #53792$#11688 + DO ;1SUB#370 <- #63912$#55428 + PLEASE ;1SUB#371 <- #7232$#45288 + DO ;1SUB#372 <- #22720$#50560 + DO ;1SUB#373 <- #55680$#16876 + DO ;1SUB#374 <- #18752$#15360 + PLEASE ;1SUB#375 <- #58112$#48256 + DO ;1SUB#376 <- #36544$#53792 + DO ;1SUB#377 <- #11688$#63912 + DO ;1SUB#378 <- #55428$#7232 + PLEASE ;1SUB#379 <- #58600$#61632 + DO ;1SUB#380 <- #50560$#55680 + DO ;1SUB#381 <- #16876$#7488 + DO ;1SUB#382 <- #46336$#59904 + PLEASE ;1SUB#383 <- #38016$#36544 + DO ;1SUB#384 <- #53792$#11688 + DO ;1SUB#385 <- #63912$#55428 + DO ;1SUB#386 <- #7232$#42216 + PLEASE ;1SUB#387 <- #28864$#50560 + DO ;1SUB#388 <- #55680$#16876 + DO ;1SUB#389 <- #19776$#48256 + DO ;1SUB#390 <- #38528$#30976 + PLEASE ;1SUB#391 <- #34368$#53792 + DO ;1SUB#392 <- #11688$#63912 + DO ;1SUB#393 <- #55428$#7232 + DO ;1SUB#394 <- #62696$#53440 + PLEASE ;1SUB#395 <- #50560$#55680 + DO ;1SUB#396 <- #16876$#19776 + DO ;1SUB#397 <- #48256$#31360 + DO ;1SUB#398 <- #32512$#53312 + PLEASE ;1SUB#399 <- #53792$#11688 + DO ;1SUB#400 <- #59816$#58560 + DO ;1SUB#401 <- #57536$#36352 + DO ;1SUB#402 <- #60864$#11264 + PLEASE ;1SUB#403 <- #29312$#21504 + DO ;1SUB#404 <- #3156$#7816 + DO ;1SUB#405 <- #59584$#47040 + DO ;1SUB#406 <- #56896$#40084 + PLEASE ;1SUB#407 <- #34440$#57024 + DO ;1SUB#408 <- #14656$#40960 + DO ;1SUB#409 <- #44032$#58496 + DO ;1SUB#410 <- #15380$#36808 + PLEASE ;1SUB#411 <- #9344$#15680 + DO ;1SUB#412 <- #15508$#57288 + DO ;1SUB#413 <- #12272$#60288 + DO ;1SUB#414 <- #43664$#11688 + PLEASE ;1SUB#415 <- #64936$#49280 + DO ;1SUB#416 <- #16384$#60288 + DO ;1SUB#417 <- #54024$#54656 + DO ;1SUB#418 <- #41608$#8160 + PLEASE ;1SUB#419 <- #144$#11688 + DO ;1SUB#420 <- #59816$#6336 + DO ;1SUB#421 <- #57536$#39424 + DO ;1SUB#422 <- #24448$#2896 + PLEASE ;1SUB#423 <- #46164$#24148 + DO ;1SUB#424 <- #60992$#58240 + DO ;1SUB#425 <- #54024$#54656 + DO ;1SUB#426 <- #42968$#27520 + PLEASE ;1SUB#427 <- #10896$#11688 + DO ;1SUB#428 <- #59816$#9408 + DO ;1SUB#429 <- #57536$#39424 + DO ;1SUB#430 <- #53200$#46164 + PLEASE ;1SUB#431 <- #24148$#34368 + DO ;1SUB#432 <- #28864$#50560 + DO ;1SUB#433 <- #9536$#32768 + DO ;1SUB#434 <- #0$#55968 + PLEASE ;1SUB#435 <- #11688$#64936 + DO ;1SUB#436 <- #15232$#52096 + DO ;1SUB#437 <- #54024$#54656 + DO ;1SUB#438 <- #62088$#11688 + PLEASE ;1SUB#439 <- #59816$#6336 + DO ;1SUB#440 <- #57536$#39424 + DO ;1SUB#441 <- #19072$#0 + DO ;1SUB#442 <- #55968$#11688 + PLEASE ;1SUB#443 <- #64936$#15232 + DO ;1SUB#444 <- #52096$#54024 + DO ;1SUB#445 <- #54656$#62088 + DO ;1SUB#446 <- #11688$#59816 + PLEASE ;1SUB#447 <- #6336$#57536 + DO ;1SUB#448 <- #39424$#19072 + DO ;1SUB#449 <- #17744$#46164 + DO ;1SUB#450 <- #24148$#48960 + PLEASE ;1SUB#451 <- #26432$#49924 + DO ;1SUB#452 <- #57920$#64324 + DO ;1SUB#453 <- #46164$#24148 + DO ;1SUB#454 <- #34368$#28864 + PLEASE ;1SUB#455 <- #50560$#9536 + DO ;1SUB#456 <- #50512$#8160 + DO ;1SUB#457 <- #22336$#5236 + DO ;1SUB#458 <- #24148$#48960 + PLEASE ;1SUB#459 <- #26432$#49924 + DO ;1SUB#460 <- #57920$#64324 + DO ;1SUB#461 <- #8160$#26432 + DO ;1SUB#462 <- #5236$#24148 + PLEASE ;1SUB#463 <- #59968$#54272 + DO ;1SUB#464 <- #7488$#49924 + DO ;1SUB#465 <- #57920$#64324 + DO ;1SUB#466 <- #46164$#24148 + PLEASE ;1SUB#467 <- #53824$#55488 + DO ;1SUB#468 <- #50560$#45120 + DO ;1SUB#469 <- #18048$#63132 + DO ;1SUB#470 <- #39636$#17608 + PLEASE ;1SUB#471 <- #63616$#39488 + DO ;1SUB#472 <- #63636$#36808 + DO ;1SUB#473 <- #55424$#15680 + DO ;1SUB#474 <- #20628$#57288 + PLEASE ;1SUB#475 <- #31392$#11688 + DO ;1SUB#476 <- #64936$#49280 + DO ;1SUB#477 <- #16384$#60288 + DO ;1SUB#478 <- #54024$#54656 + PLEASE ;1SUB#479 <- #62088$#11688 + DO ;1SUB#480 <- #59816$#58560 + DO ;1SUB#481 <- #57536$#51968 + DO ;1SUB#482 <- #44496$#46164 + PLEASE ;1SUB#483 <- #24148$#54848 + DO ;1SUB#484 <- #53440$#50560 + DO ;1SUB#485 <- #50752$#31392 + DO ;1SUB#486 <- #11688$#64936 + PLEASE ;1SUB#487 <- #49280$#9472 + DO ;1SUB#488 <- #16768$#54024 + DO ;1SUB#489 <- #54656$#62088 + DO ;1SUB#490 <- #11688$#47276 + PLEASE ;1SUB#491 <- #45568$#17236 + DO ;1SUB#492 <- #35144$#12928 + DO ;1SUB#493 <- #56744$#11136 + DO ;1SUB#494 <- #47760$#46164 + PLEASE ;1SUB#495 <- #24148$#34368 + DO ;1SUB#496 <- #28864$#50560 + DO ;1SUB#497 <- #61440$#48832 + DO ;1SUB#498 <- #32064$#48276 + PLEASE ;1SUB#499 <- #36808$#48192 + DO ;1SUB#500 <- #23552$#62784 + DO ;1SUB#501 <- #15488$#65216 + DO ;1SUB#502 <- #28012$#11904 + PLEASE ;1SUB#503 <- #22592$#64032 + DO ;1SUB#504 <- #11688$#59816 + DO ;1SUB#505 <- #6336$#57536 + DO ;1SUB#506 <- #51712$#23252 + PLEASE ;1SUB#507 <- #36808$#63552 + DO ;1SUB#508 <- #58368$#23252 + DO ;1SUB#509 <- #40904$#3072 + DO ;1SUB#510 <- #18832$#46164 + PLEASE ;1SUB#511 <- #24148$#60992 + DO ;1SUB#512 <- #58240$#54024 + DO ;1SUB#513 <- #54656$#62088 + DO ;1SUB#514 <- #11688$#59816 + PLEASE ;1SUB#515 <- #59584$#57536 + DO ;1SUB#516 <- #51968$#45520 + DO ;1SUB#517 <- #46164$#24148 + DO ;1SUB#518 <- #34368$#28864 + PLEASE ;1SUB#519 <- #50560$#50752 + DO ;1SUB#520 <- #31392$#11688 + DO ;1SUB#521 <- #64936$#49280 + DO ;1SUB#522 <- #49152$#27520 + PLEASE ;1SUB#523 <- #54024$#54656 + DO ;1SUB#524 <- #62088$#11688 + DO ;1SUB#525 <- #59816$#59584 + DO ;1SUB#526 <- #57536$#51968 + PLEASE ;1SUB#527 <- #40400$#46164 + DO ;1SUB#528 <- #24148$#52936 + DO ;1SUB#529 <- #42624$#43904 + DO ;1SUB#530 <- #37544$#4048 + DO .7 <- #1 + DO ,1 <- #4 + DO COME FROM (5) + DO .5 <- '?"&.7~#3"$#1'~#3 + DO (2) NEXT + DO :1 <- #57364$#58240 + DO (7) NEXT + DO :1 <- #19776$#2436 + DO (3) NEXT +(2) DO (1001) NEXT + DO :1 <- #46164$#7684 +(3) DO FORGET #1 + DO (7) NEXT + DO :1 <- #39712$#41992 + DO (7) NEXT + DO .6 <- #170 + DO .2 <- #66 + DO (6) NEXT + DO .1 <- .7 + DO (9) NEXT + DO .2 <- #4 + DO (6) NEXT + DO :1 <- #57536$#39424 + DO (7) NEXT + DO .6 <- #196 + DO .1 <- ';1SUB.7'~'#65535$#0' + DO (90) NEXT + DO .2 <- #36 + DO (6) NEXT + DO .1 <- ';1SUB.7'~'#0$#65535' + DO (9) NEXT + DO .2 <- #80 + DO (6) NEXT + DO .5 <- "?'"#65535~'"?.7$!9~#65532'"~"#0$#65535"'"~#1'$#1"~#3 + DO (4) NEXT + DO .1 <- .7 + DO (1020) NEXT +(5) DO .7 <- .1 +(4) DO (1001) NEXT + DO FORGET #1 + DO (8) NEXT + DO READ OUT ,1 + DO GIVE UP + +(1) DO .6 <- #2120 + DO ;1 <- .6~#65532 + DO ;1SUB#1 <- #15956$#24148 + DO ;1SUB#2 <- #59968$#60288 + DO ;1SUB#3 <- #54024$#54656 + DO .9 <- #12 + DO (8) NEXT + DO .9 <- .6 + DO ,6 <- #1 + DO ,6SUB#1 <- #218 + DO READ OUT ,1 + ,6 + DO .6 <- #80 + DO RESUME #1 + +(6) DO STASH .1 + .3 + DO .1 <- .6 + DO (1010) NEXT + DO ,6SUB#1 <- .3~#255 + DO READ OUT ,6 + DO .6 <- .2 + DO RETRIEVE .1 + .3 + DO RESUME #1 + +(7) DO ,1SUB#1 <- :1~'#43690$#0' + DO ,1SUB#2 <- :1~'#21845$#0' + DO ,1SUB#3 <- :1~'#0$#43690' + DO ,1SUB#4 <- :1~'#0$#21845' + DO READ OUT ,1 + DO RESUME #1 + +(8) DO ,1 <- .9 + DO .1 <- #0 + DO COME FROM (81) + DO (1020) NEXT + DO .4 <- .1 + DO (1020) NEXT + DO .3 <- .1 + DO (1020) NEXT + DO .2 <- .1 + DO (1020) NEXT + DO :1 <- ;1SUB!1~#65532' + DO ,1SUB.4 <- :1~'#43690$#0' + DO ,1SUB.3 <- :1~'#21845$#0' + DO ,1SUB.2 <- :1~'#0$#43690' + DO ,1SUB.1 <- :1~'#0$#21845' + DO .5 <- '?"'#65535~"'?.9$.1'~'#0$#65535'"'~#1"$#2'~#3 +(81) DO (1001) NEXT + +(9) DO .2 <- #196 + DO (6) NEXT +(90) DO .4 <- #0 + DO .2 <- #10000 + DO (92) NEXT + DO .2 <- #1000 + DO (92) NEXT + DO .2 <- #100 + DO (92) NEXT + DO .2 <- #10 +(91) DO (92) NEXT +(92) DO (1040) NEXT + DO .5 <- "?'"V!3~.3'$.4"~#1'$#2"~#3 + DO (1001) NEXT + DO .5 <- .1 + DO .1 <- .3 + DO (1039) NEXT + DO COME FROM (91) + DO .2 <- "!1$#3'~#15"$"!1$#3'~#240" + DO .2 <- !2~#15'$!2~#240' + DO (6) NEXT + DO .1 <- .5 + DO .2 <- .3 + DO (1010) NEXT + DO .1 <- .3 + DO RESUME #1 diff --git a/pit/rot13.doc b/pit/rot13.doc new file mode 100644 index 0000000..36e8786 --- /dev/null +++ b/pit/rot13.doc @@ -0,0 +1,16 @@ + +From: jlm@cco.caltech.edu (Jacob Mandelson) +Newsgroups: alt.lang.intercal +Subject: Re: ROT-13 +Date: 7 Jun 1993 21:36:40 GMT +Organization: California Institute of Technology, Pasadena +Message-ID: <1v0cd9INN8gk@gap.caltech.edu> + +Here's an intercal program that encodes/decodes rot13 documents: + +[Program moved to separate file and modified to satisfy the + politeness rules, LHH 5/11/96.] + +-- + Jacob Mandelson jlm@cco.caltech.edu + Electrical engineers do it with less resistance. diff --git a/pit/rot13.i b/pit/rot13.i index 17abe6e..58f5e6e 100644 --- a/pit/rot13.i +++ b/pit/rot13.i @@ -1,128 +1,128 @@ -(10) PLEASE DON'T GIVE UP -(1) DO .2 <- '?.1$#64'~'#0$#65535' - DO .2 <- '&"'.1~.2'~'"?'?.2~.2'$#32768"~"#0$#65535"'"$".2~.2"'~#1 - DO .3 <- '?#91$.1'~'#0$#65535' - DO .3 <- '&"'#91~.3'~'"?'?.3~.3'$#32768"~"#0$#65535"'"$".3~.3"'~#1 - PLEASE DO (11) NEXT - PLEASE DO (2) NEXT - PLEASE DO (12) NEXT -(11) PLEASE DO (13) NEXT - PLEASE FORGET #1 - PLEASE DO (12) NEXT -(13) PLEASE DO (14) NEXT - PLEASE FORGET #2 - PLEASE DO (12) NEXT -(14) DO STASH .1 - DO .1 <- .3 - PLEASE DO (1000) NEXT - DO .1 <- .3 - DO .2 <- #1 - PLEASE DO (1000) NEXT - DO RETRIEVE .1 - DO RESUME .3 -(12) PLEASE FORGET #1 - DO .2 <- '?.1$#96'~'#0$#65535' - DO .2 <- '&"'.1~.2'~'"?'?.2~.2'$#32768"~"#0$#65535"'"$".2~.2"'~#1 - DO .3 <- '?#123$.1'~'#0$#65535' - DO .3 <- '&"'#123~.3'~'"?'?.3~.3'$#32768"~"#0$#65535"'"$".3~.3"'~#1 - PLEASE DO (15) NEXT - PLEASE DO (3) NEXT - PLEASE DO (16) NEXT -(15) PLEASE DO (17) NEXT - PLEASE FORGET #1 - DO (16) NEXT -(17) DO (18) NEXT - DO FORGET #2 - DO (16) NEXT -(18) DO STASH .1 - DO .1 <- .3 - DO (1000) NEXT - DO .1 <- .3 - DO .2 <- #1 - DO (1000) NEXT - DO RETRIEVE .1 - DO RESUME .3 -(16) DO FORGET #1 - DO RESUME #1 -(2) DO .2 <- #65 - DO (1010) NEXT - DO .1 <- .3 - DO .2 <- #13 - DO (1000) NEXT - DO STASH .3 - DO .1 <- .3 - DO .2 <- #26 - DO (1040) NEXT - DO .1 <- .3 - DO (1030) NEXT - DO .2 <- .3 - DO RETRIEVE .3 - DO .1 <- .3 - DO (1010) NEXT - DO .1 <- .3 - DO .2 <- #65 - DO (1000) NEXT - DO .1 <- .3 - DO RESUME #1 -(3) DO .2 <- #97 - DO (1010) NEXT - DO .1 <- .3 - DO .2 <- #13 - DO (1000) NEXT - DO STASH .3 - DO .1 <- .3 - DO .2 <- #26 - DO (1040) NEXT - DO .1 <- .3 - DO (1030) NEXT - DO .2 <- .3 - DO RETRIEVE .3 - DO .1 <- .3 - DO (1010) NEXT - DO .1 <- .3 - DO .2 <- #97 - DO (1000) NEXT - DO .1 <- .3 - DO RESUME #1 - DO COME FROM (10) - DO .4 <- #0 - DO .5 <- #0 - DO STASH .4 + .5 - DO ,1 <- #1 - DO COME FROM (33) - DO WRITE IN ,1 - DO .1 <- ,1 SUB #1 - DO (31) NEXT - PLEASE DO .6 <- #1 - PLEASE DO (34) NEXT -(32) PLEASE RESUME '?.1$#256'~'#256$#256' -(31) DO (32) NEXT - DO FORGET #1 - DO .6 <- #0 - PLEASE DO (34) NEXT -(33) DON'T GIVE UP -(34) DO .6 <- "?!6'$#1"~#3 - DO (40) NEXT - DO GIVE UP -(40) DO (41) NEXT - PLEASE FORGET #1 - DO (42) NEXT -(41) DO RESUME .6 -(42) DO FORGET #1 - DO RETRIEVE .4 - DO .2 <- .4 - DO (1000) NEXT - DO .4 <- .3~#255 - DO .3 <- .4 - DO STASH .4 - DO .1 <- .3 - DO (1) NEXT - DO .3 <- !1~#15'$!1~#240' - DO .3 <- !3~#15'$!3~#240' - DO .2 <- !3~#15'$!3~#240' - DO .1 <- .5 - DO (1010) NEXT - DO .5 <- .2 - DO ,1 SUB #1 <- .3 - PLEASE READ OUT ,1 - PLEASE RESUME #1 +(10) PLEASE DON'T GIVE UP +(1) DO .2 <- '?.1$#64'~'#0$#65535' +DO .2 <- '&"'.1~.2'~'"?'?.2~.2'$#32768"~"#0$#65535"'"$".2~.2"'~#1 +DO .3 <- '?#91$.1'~'#0$#65535' +DO .3 <- '&"'#91~.3'~'"?'?.3~.3'$#32768"~"#0$#65535"'"$".3~.3"'~#1 +DO (11) NEXT +DO (2) NEXT +DO (12) NEXT +(11) DO (13) NEXT +PLEASE FORGET #1 +DO (12) NEXT +(13) DO (14) NEXT +PLEASE FORGET #2 +DO (12) NEXT +(14) DO STASH .1 +DO .1 <- .3 +DO (1000) NEXT +DO .1 <- .3 +DO .2 <- #1 +PLEASE DO (1000) NEXT +DO RETRIEVE .1 +PLEASE RESUME .3 +(12) PLEASE FORGET #1 +DO .2 <- '?.1$#96'~'#0$#65535' +DO .2 <- '&"'.1~.2'~'"?'?.2~.2'$#32768"~"#0$#65535"'"$".2~.2"'~#1 +DO .3 <- '?#123$.1'~'#0$#65535' +DO .3 <- '&"'#123~.3'~'"?'?.3~.3'$#32768"~"#0$#65535"'"$".3~.3"'~#1 +PLEASE DO (15) NEXT +PLEASE DO (3) NEXT +DO (16) NEXT +(15) DO (17) NEXT +PLEASE FORGET #1 +DO (16) NEXT +(17) DO (18) NEXT +PLEASE FORGET #2 +DO (16) NEXT +(18) PLEASE STASH .1 +DO .1 <- .3 +DO (1000) NEXT +DO .1 <- .3 +DO .2 <- #1 +DO (1000) NEXT +PLEASE RETRIEVE .1 +PLEASE RESUME .3 +(16) PLEASE FORGET #1 +DO RESUME #1 +(2) DO .2 <- #65 +DO (1010) NEXT +PLEASE .1 <- .3 +PLEASE .2 <- #13 +DO (1000) NEXT +PLEASE STASH .3 +DO .1 <- .3 +DO .2 <- #26 +DO (1040) NEXT +DO .1 <- .3 +DO (1030) NEXT +DO .2 <- .3 +PLEASE RETRIEVE .3 +DO .1 <- .3 +DO (1010) NEXT +DO .1 <- .3 +DO .2 <- #65 +DO (1000) NEXT +DO .1 <- .3 +DO RESUME #1 +(3) DO .2 <- #97 +DO (1010) NEXT +DO .1 <- .3 +DO .2 <- #13 +DO (1000) NEXT +DO STASH .3 +DO .1 <- .3 +DO .2 <- #26 +DO (1040) NEXT +DO .1 <- .3 +DO (1030) NEXT +DO .2 <- .3 +DO RETRIEVE .3 +DO .1 <- .3 +DO (1010) NEXT +DO .1 <- .3 +DO .2 <- #97 +DO (1000) NEXT +DO .1 <- .3 +PLEASE RESUME #1 +DO COME FROM (10) +DO .4 <- #0 +DO .5 <- #0 +DO STASH .4 + .5 +DO ,1 <- #1 +DO COME FROM (33) +DO WRITE IN ,1 +DO .1 <- ,1 SUB #1 +DO (31) NEXT +PLEASE DO .6 <- #1 +PLEASE DO (34) NEXT +(32) PLEASE RESUME '?.1$#256'~'#256$#256' +(31) DO (32) NEXT +DO FORGET #1 +DO .6 <- #0 +PLEASE DO (34) NEXT +(33) DON'T GIVE UP +(34) DO .6 <- "?!6'$#1"~#3 +DO (40) NEXT +DO GIVE UP +(40) DO (41) NEXT +PLEASE FORGET #1 +DO (42) NEXT +(41) DO RESUME .6 +(42) DO FORGET #1 +DO RETRIEVE .4 +DO .2 <- .4 +DO (1000) NEXT +DO .4 <- .3~#255 +DO .3 <- .4 +DO STASH .4 +DO .1 <- .3 +DO (1) NEXT +DO .3 <- !1~#15'$!1~#240' +DO .3 <- !3~#15'$!3~#240' +DO .2 <- !3~#15'$!3~#240' +DO .1 <- .5 +DO (1010) NEXT +DO .5 <- .2 +DO ,1 SUB #1 <- .3 +PLEASE READ OUT ,1 +PLEASE RESUME #1 diff --git a/pit/rot13b.doc b/pit/rot13b.doc new file mode 100644 index 0000000..ed891de --- /dev/null +++ b/pit/rot13b.doc @@ -0,0 +1,117 @@ + +Newsgroups: alt.folklore.computers,alt.lang.intercal +From: clmeier@lili6.lili.uni-bielefeld.de (Clemens Meier) +Subject: Re: Duplicated programming language names? +Message-ID: +Date: Fri, 22 Dec 1995 13:11:11 GMT +Organization: Universitaet Bielefeld, Linguistik und Literaturwissenschaft, Germany + +> Mahlzeit + +Wohl bekomm's! + +> > Programming Language (someone wrote an INTERCAL ROT-13 program which +> > takes about 4 pages of completely indecipherable code). +> +> Where can I get it???!!! + +What? + +INTERCAL? At the Retrocomputing Museum: + http://www.ccil.org/retro/retromuseum.html + +The ROT-13 program? Exercise is left to the reader. + +My solution is only slightly bigger than one page +and could be further shortened. It is, of course, +ROT-13 encoded and has a kind of Welsh touch, IMHO. + +Happy Chrismas and New Year, or, for +Kenneth: Chrismas Year New and Happy! + +Clemens + +---------------------------------------------------------->8--------- + QB ,1 <- #1 + QB .4 <- #0 + QB .5 <- #0 + QB PBZR SEBZ (30) + QB JEVGR VA ,1 + QB .1 <- ,1FHO#1 + QB (10) ARKG + CYRNFR TVIR HC +(20) CYRNFR ERFHZR '?.1$#256'~'#256$#256' +(10) QB (20) ARKG + QB SBETRG #1 + QB .2 <- .4 + QB (1000) ARKG + QB .4 <- .3~#255 + QB (50) ARKG + QB .3 <- !3~#15'$!3~#240' + QB .3 <- !3~#15'$!3~#240' + QB .2 <- !3~#15'$!3~#240' + QB .1 <- .5 + QB (1010) ARKG + QB .5 <- .2 + CYRNFR QB ,1FHO#1 <- .3 +(30) CYRNFR ERNQ BHG ,1 + +(50) CYRNFR FGNFU .1 + .2 + .4 + .5 + .11+.12+.13+.14+.15+.16+.17+.18 + CYRNFR QB .5 <- .4 + CYRNFR QB .1 <- .5 + QB .2 <- #65 + QB (500) ARKG + QB .11 <- .3~#2 + QB .2 <- #78 + QB (500) ARKG + QB .12 <- .3~#2 + QB .2 <- #97 + QB (500) ARKG + QB .13 <- .3~#2 + QB .2 <- #110 + QB (500) ARKG + QB .14 <- .3~#2 + CYRNFR QB .2 <- .5 + QB .1 <- #77 + QB (500) ARKG + QB .15 <- .3~#2 + QB .1 <- #90 + QB (500) ARKG + QB .16 <- .3~#2 + QB .1 <- #109 + QB (500) ARKG + QB .17 <- .3~#2 + QB .1 <- #122 + QB (500) ARKG + QB .18 <- .3~#2 + CYRNFR QB .1 <- ' "'"!12$.11'~#3"$"!14$.13'~#3"'~#15" + $"'"!16$.15'~#3"$"!18$.17'~#3"'~#15" '~#255 + CYRNFR QB .1 <- 'I"!&1'~#85"'~#5 + QB .2 <- "!1~#2'$!1~#2'"~#3 + QB .1 <- !2$.1'~#15 + QB .2 <- !2$.2'~#15 + QB .2 <- "!1$.2'$!1$"'"I!2$.1'"~#15'"'"~#65535 + QB .1 <- .5 + CYRNFR QB (1009) ARKG + CYRNFR ERGEVRIR .1 + .2 + .4 + .5 + .11+.12+.13+.14+.15+.16+.17+.18 + CYRNFR ERFHZR #1 + +(500) CYRNFR FGNFU .4 + QB .3 <- "?!1$.2'"~"#0$#65535" + QB .4 <- .3~.3 + QB .4 <- '&"!?4'$.4"'~'#0$#65535' + QB .3 <- '"'&"!1~.3'$.4"'~'#0$#65535'"~.4' + $'"'&"!2~.3'$.4"'~'#0$#65535'"~.4' + QB .3 <- "?'"!3~#1'$!3~#2'"$"#1$!3~#1'"'"~#5 + CYRNFR ERGEVRIR .4 + QB ERFHZR #1 +---------------------------------------------------------->8--------- + +> I LOVE MY PDP-11/34A! + +Then you'll be right at home in this group. +-- +---------------------------------------------------------------------------- +> Wo ist denn der Objoke ??? Clemens Meier +Bei Clemens? Nie!! Ok, ok, aber fast nie. clmeier@lili.uni-bielefeld.de + GO C+ UL P- L+>++>+++ 3$ E++>+++ N++ R+>+++ G'''' !tv b++ D f? TWERPS+++ diff --git a/pit/rot13b.i b/pit/rot13b.i new file mode 100644 index 0000000..89c2a64 --- /dev/null +++ b/pit/rot13b.i @@ -0,0 +1,74 @@ + + DO ,1 <- #1 + DO .4 <- #0 + DO .5 <- #0 + DO COME FROM (30) + DO WRITE IN ,1 + DO .1 <- ,1SUB#1 + DO (10) NEXT + PLEASE GIVE UP +(20) PLEASE RESUME '?.1$#256'~'#256$#256' +(10) DO (20) NEXT + DO FORGET #1 + DO .2 <- .4 + DO (1000) NEXT + DO .4 <- .3~#255 + DO (50) NEXT + DO .3 <- !3~#15'$!3~#240' + DO .3 <- !3~#15'$!3~#240' + DO .2 <- !3~#15'$!3~#240' + DO .1 <- .5 + DO (1010) NEXT + DO .5 <- .2 + PLEASE DO ,1SUB#1 <- .3 +(30) PLEASE READ OUT ,1 + +(50) PLEASE STASH .1 + .2 + .4 + .5 + .11+.12+.13+.14+.15+.16+.17+.18 + PLEASE DO .5 <- .4 + PLEASE DO .1 <- .5 + DO .2 <- #65 + DO (500) NEXT + DO .11 <- .3~#2 + DO .2 <- #78 + DO (500) NEXT + DO .12 <- .3~#2 + DO .2 <- #97 + DO (500) NEXT + DO .13 <- .3~#2 + DO .2 <- #110 + DO (500) NEXT + DO .14 <- .3~#2 + PLEASE DO .2 <- .5 + DO .1 <- #77 + DO (500) NEXT + DO .15 <- .3~#2 + DO .1 <- #90 + DO (500) NEXT + DO .16 <- .3~#2 + DO .1 <- #109 + DO (500) NEXT + DO .17 <- .3~#2 + DO .1 <- #122 + DO (500) NEXT + DO .18 <- .3~#2 + PLEASE DO .1 <- ' "'"!12$.11'~#3"$"!14$.13'~#3"'~#15" + $"'"!16$.15'~#3"$"!18$.17'~#3"'~#15" '~#255 + PLEASE DO .1 <- 'V"!&1'~#85"'~#5 + DO .2 <- "!1~#2'$!1~#2'"~#3 + DO .1 <- !2$.1'~#15 + DO .2 <- !2$.2'~#15 + DO .2 <- "!1$.2'$!1$"'"V!2$.1'"~#15'"'"~#65535 + DO .1 <- .5 + PLEASE DO (1009) NEXT + PLEASE RETRIEVE .1 + .2 + .4 + .5 + .11+.12+.13+.14+.15+.16+.17+.18 + PLEASE RESUME #1 + +(500) PLEASE STASH .4 + DO .3 <- "?!1$.2'"~"#0$#65535" + DO .4 <- .3~.3 + DO .4 <- '&"!?4'$.4"'~'#0$#65535' + DO .3 <- '"'&"!1~.3'$.4"'~'#0$#65535'"~.4' + $'"'&"!2~.3'$.4"'~'#0$#65535'"~.4' + DO .3 <- "?'"!3~#1'$!3~#2'"$"#1$!3~#1'"'"~#5 + PLEASE RETRIEVE .4 + DO RESUME #1 diff --git a/pit/tests/limits.3i b/pit/tests/limits.3i index 3abd646..0c62541 100644 --- a/pit/tests/limits.3i +++ b/pit/tests/limits.3i @@ -1,4 +1,4 @@ - PLEASE DO .1 <- #59048 + DO .1 <- #59048 DO :1 <- #59048 DO WRITE IN .1 + :1 DO READ OUT .1 + :1 diff --git a/pit/tests/testops.5i b/pit/tests/testops.5i index c0ca101..c00ed20 100644 --- a/pit/tests/testops.5i +++ b/pit/tests/testops.5i @@ -13,5 +13,5 @@ DO .1 <- "3@.3$#1"~#1 DO READ OUT .1 DO .1 <- "V.3$#1"~#1 - PLEASE DO READ OUT .1 + DO READ OUT .1 PLEASE GIVE UP diff --git a/pit/tests/testsplat.i b/pit/tests/testsplat.i index 73312e1..ea8b68e 100644 --- a/pit/tests/testsplat.i +++ b/pit/tests/testsplat.i @@ -7,4 +7,4 @@ OUT #8 DO READ OUTT #9 - DO PLEASE GIVE UP + PLEASE DO GIVE UP diff --git a/pit/tophat.fft b/pit/tophat.fft new file mode 100644 index 0000000..453a687 --- /dev/null +++ b/pit/tophat.fft @@ -0,0 +1,258 @@ +ONE +ONE TWO EIGHT +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO +ONE TWO FIVE OH OH OH OH FIVE ONE +ZERO diff --git a/pit/yapp.doc b/pit/yapp.doc new file mode 100644 index 0000000..7e63709 --- /dev/null +++ b/pit/yapp.doc @@ -0,0 +1,26 @@ +yapp stands for "yet another program printer", or "yet another +printing program", or maybe "yet another printer printer". yapp is a +program that prints out programs that print out. + +That is, yapp takes whatever is piped into its standard input, and +produces on its standard output the source code for an INTERCAL +program that will, when compiled, produce the original file. The +created program will be self-contained; it will not need the system +library to compile. The reason for this is to maximize the amount of +data that yapp can encode into an INTERCAL program. The current +compiler has an upper bound on the number of commands one program can +have; thus yapp will not produce a compilable program if given more +than 3880 bytes. + +Though yapp was intended to create standalone programs, it can also be +used to generate subroutines. (In fact, the first working version of +this program was used to generate the lines for the final draft.) In +such a case, it is convenient to specify what character the data will +"follow". The easiest way to accomplish this is to replace the "DO .9 +<- #0" in line 22 with "DO .9 <- ", where is the +bit-reversed code of the character preceeding the data (#80 in the +case of a newline, for example). A more versatile modification is to +change line 22 to "DO WRITE IN .9", and then insert the character code +at the top of the file that is to be fed to yapp. Thus, if the data in +the file would follow a newline, the line "EIGHT OH" would be added to +the top of the data file. diff --git a/pit/yapp.i b/pit/yapp.i new file mode 100644 index 0000000..479a862 --- /dev/null +++ b/pit/yapp.i @@ -0,0 +1,414 @@ + DO (3990) NEXT + PLEASE DO ;1 <- #128 + PLEASE DO ,2 <- #2 + DO ,2SUB#1 <- #136 + DO ,2SUB#2 <- #240 + PLEASE DO ,4 <- #4 + + DO ;1SUB#1 <- #42920$#47080 + DO ;1SUB#2 <- #1156$#57920 + PLEASE ;1SUB#3 <- #64324$#3496 + DO ;1SUB#4 <- #4904$#25152 + DO ;1SUB#5 <- #12352$#52716 + DO ;1SUB#6 <- #29312$#21504 + PLEASE ;1SUB#7 <- #54608$#3496 + DO ;1SUB#8 <- #52968$#25152 + DO ;1SUB#9 <- #12352$#42740 + DO ;1SUB#10 <- #8020$#47488 + PLEASE ;1SUB#11 <- #54656$#53200 + DO .4 <- #44 + DO (100) NEXT + + DO .9 <- #0 + DO .7 <- #0 + PLEASE COME FROM (50) + DO .6 <- #0 + PLEASE COME FROM (5) + DO (3000) NEXT + DO .5 <- '?".1~#256"$#2'~#3 + DO (49) NEXT + DO .2 <- !1~#15'$!1~#240' + DO .2 <- !2~#15'$!2~#240' + DO .2 <- !2~#15'$!2~#240' + DO .1 <- .9 + DO .9 <- .2 + DO (1010) NEXT + DO .1 <- .6 + DO (1020) NEXT + DO .6 <- .1 + DO ,4SUB.6 <- .3~#255 + DO .5 <- '?".6~#4"$#2'~#3 +(5) DO (4) NEXT +(4) DO (1001) NEXT + PLEASE FORGET #1 + DO .6 <- #0 + DO .1 <- .7 + DO (1020) NEXT + DO .7 <- .1 + DO .5 <- '?".&7~#1"$#1'~#3 + DO (7) NEXT + DO ;1SUB#1 <- #29032$#34304 + DO ;1SUB#2 <- #36544$#45352 + DO ;1SUB#3 <- #41992$#15828 + DO .4 <- #12 + DO (8) NEXT +(7) DO (1001) NEXT + DO ;1SUB#1 <- #3496$#4904 + DO ;1SUB#2 <- #41992$#15828 + DO .4 <- #8 +(8) PLEASE FORGET #1 + DO (100) NEXT + DO .1 <- .7 + DO (220) NEXT + DO .1 <- ',4SUB#1'$',4SUB#2' + DO ,3001SUB#1 <- #196 + DO (3090) NEXT + DO .2 <- #36 + DO (3001) NEXT + DO .2 <- #196 + DO (3001) NEXT + DO .1 <- ',4SUB#3'$',4SUB#4' +(50) DO (200) NEXT +(49) DO (1001) NEXT + PLEASE FORGET #1 + + DO ;1SUB#1 <- #29032$#34304 + DO ;1SUB#2 <- #36544$#63744 + PLEASE ;1SUB#3 <- #8448$#8512 + DO ;1SUB#4 <- #12928$#49896 + DO ;1SUB#5 <- #47760$#3496 + DO ;1SUB#6 <- #12008$#16960 + PLEASE ;1SUB#7 <- #29760$#3828 + DO ;1SUB#8 <- #8020$#51584 + DO ;1SUB#9 <- #54656$#54224 + DO ;1SUB#10 <- #29032$#34304 + PLEASE ;1SUB#11 <- #36544$#63744 + DO ;1SUB#12 <- #8448$#8512 + DO ;1SUB#13 <- #12928$#37608 + DO ;1SUB#14 <- #6800$#3496 + PLEASE ;1SUB#15 <- #31464$#27200 + DO ;1SUB#16 <- #63040$#56192 + DO ;1SUB#17 <- #43220$#17608 + DO ;1SUB#18 <- #33920$#11584 + PLEASE ;1SUB#19 <- #40084$#57288 + DO ;1SUB#20 <- #12020$#8020 + DO ;1SUB#21 <- #47488$#53632 + DO ;1SUB#22 <- #59584$#48320 + PLEASE ;1SUB#23 <- #52800$#48276 + DO ;1SUB#24 <- #34440$#57024 + DO ;1SUB#25 <- #14656$#40960 + DO ;1SUB#26 <- #44032$#57744 + PLEASE ;1SUB#27 <- #3496$#63208 + DO ;1SUB#28 <- #34436$#57920 + DO ;1SUB#29 <- #64324$#6880 + DO ;1SUB#30 <- #8068$#8020 + PLEASE ;1SUB#31 <- #51584$#34176 + DO ;1SUB#32 <- #52928$#27968 + DO ;1SUB#33 <- #7316$#34440 + DO ;1SUB#34 <- #60032$#26624 + PLEASE ;1SUB#35 <- #53312$#11584 + DO ;1SUB#36 <- #51600$#24288 + DO ;1SUB#37 <- #38788$#23380 + DO ;1SUB#38 <- #10688$#22792 + PLEASE ;1SUB#39 <- #54656$#45724 + DO ;1SUB#40 <- #58240$#19776 + DO ;1SUB#41 <- #6272$#28224 + DO ;1SUB#42 <- #14464$#16020 + PLEASE ;1SUB#43 <- #4048$#3496 + DO ;1SUB#44 <- #54056$#25152 + DO ;1SUB#45 <- #45952$#41992 + DO ;1SUB#46 <- #28116$#43732 + PLEASE ;1SUB#47 <- #39880$#40960 + DO ;1SUB#48 <- #59392$#27024 + DO ;1SUB#49 <- #3496$#52968 + DO ;1SUB#50 <- #41992$#32212 + PLEASE ;1SUB#51 <- #42304$#7296 + DO ;1SUB#52 <- #20160$#26988 + DO ;1SUB#53 <- #6464$#40960 + DO ;1SUB#54 <- #59392$#7296 + PLEASE ;1SUB#55 <- #65216$#34880 + DO ;1SUB#56 <- #37312$#41556 + DO ;1SUB#57 <- #34440$#38528 + DO ;1SUB#58 <- #30976$#54848 + PLEASE ;1SUB#59 <- #27968$#18832 + DO ;1SUB#60 <- #3496$#52968 + DO ;1SUB#61 <- #41992$#32212 + DO ;1SUB#62 <- #42304$#7296 + PLEASE ;1SUB#63 <- #16064$#26988 + DO ;1SUB#64 <- #6464$#40960 + DO ;1SUB#65 <- #59392$#7296 + DO ;1SUB#66 <- #65216$#34880 + PLEASE ;1SUB#67 <- #37312$#41556 + DO ;1SUB#68 <- #34440$#31360 + DO ;1SUB#69 <- #32512$#49216 + DO ;1SUB#70 <- #27968$#18832 + PLEASE ;1SUB#71 <- #3496$#52968 + DO ;1SUB#72 <- #41992$#32212 + DO ;1SUB#73 <- #42304$#7296 + DO ;1SUB#74 <- #65216$#26988 + PLEASE ;1SUB#75 <- #6464$#40960 + DO ;1SUB#76 <- #59392$#7296 + DO ;1SUB#77 <- #65216$#34880 + DO ;1SUB#78 <- #37312$#41556 + PLEASE ;1SUB#79 <- #34440$#57024 + DO ;1SUB#80 <- #26944$#15360 + DO ;1SUB#81 <- #58112$#18832 + DO ;1SUB#82 <- #3496$#52968 + PLEASE ;1SUB#83 <- #41992$#30932 + DO ;1SUB#84 <- #47488$#37312 + DO ;1SUB#85 <- #41556$#34440 + DO ;1SUB#86 <- #57024$#15680 + PLEASE ;1SUB#87 <- #46336$#59904 + DO ;1SUB#88 <- #57744$#3496 + DO ;1SUB#89 <- #31464$#27200 + DO ;1SUB#90 <- #63040$#40576 + PLEASE ;1SUB#91 <- #6464$#40960 + DO ;1SUB#92 <- #44032$#3564 + DO ;1SUB#93 <- #31808$#37056 + DO ;1SUB#94 <- #17792$#60608 + PLEASE ;1SUB#95 <- #26988$#19776 + DO ;1SUB#96 <- #48256$#29312 + DO ;1SUB#97 <- #21504$#37952 + DO ;1SUB#98 <- #39936$#28012 + PLEASE ;1SUB#99 <- #6848$#7168 + DO ;1SUB#100 <- #20160$#28012 + DO ;1SUB#101 <- #49104$#19168 + DO ;1SUB#102 <- #49028$#23380 + PLEASE ;1SUB#103 <- #58816$#22792 + DO ;1SUB#104 <- #54656$#42968 + DO ;1SUB#105 <- #58816$#12040 + DO ;1SUB#106 <- #46824$#1668 + PLEASE ;1SUB#107 <- #57920$#64324 + DO .4 <- #428 + DO (100) NEXT + + DO .5 <- '?"!6~.6'~#1"$#1'~#3 + DO (80) NEXT + DO ;1SUB#1 <- #3496$#52416 + DO ;1SUB#2 <- #7168$#6720 + PLEASE ;1SUB#3 <- #54548$#36304 + DO ;1SUB#4 <- #1108$#20308 + DO ;1SUB#5 <- #39296$#54656 + DO .4 <- #20 + DO (100) NEXT + DO .1 <- .6 + DO (200) NEXT + DO .8 <- #1 + PLEASE COME FROM (60) + DO ;1SUB#1 <- #3496$#52968 + DO ;1SUB#2 <- #41992$#15828 + DO .4 <- #8 + DO (100) NEXT + DO .1 <- .8 + DO (220) NEXT + DO .1 <- ,4SUB.8 + DO (200) NEXT + DO .5 <- '?"'#15~"'?.8$.6'~#5"'~#1"$#1'~#3 + DO (80) NEXT + DO .1 <- .8 + DO (1020) NEXT +(60) DO .8 <- .1 +(80) DO (1001) NEXT +(79) PLEASE FORGET #1 + DO ;1SUB#1 <- #29032$#34304 + DO ;1SUB#2 <- #36544$#13568 + PLEASE ;1SUB#3 <- #40128$#13632 + DO ;1SUB#4 <- #11624$#3828 + DO ;1SUB#5 <- #20032$#35968 + DO ;1SUB#6 <- #11520$#24704 + PLEASE ;1SUB#7 <- #61032$#6836 + DO ;1SUB#8 <- #58240$#19776 + DO ;1SUB#9 <- #22656$#9792 + DO ;1SUB#10 <- #62912$#52548 + PLEASE ;1SUB#11 <- #7904$#17092 + DO ;1SUB#12 <- #58240$#19776 + DO ;1SUB#13 <- #6592$#55744 + DO ;1SUB#14 <- #23872$#1620 + PLEASE ;1SUB#15 <- #45520$#8160 + DO ;1SUB#16 <- #5508$#8020 + DO ;1SUB#17 <- #30080$#54656 + DO .4 <- #68 + DO (100) NEXT + DO .1 <- '"!7$#0'~'#16383$#1'"$#0'~'#32767$#1' + DO (200) NEXT + DO ;1SUB#1 <- #29032$#34304 + DO ;1SUB#2 <- #36544$#26304 + PLEASE ;1SUB#3 <- #42624$#43904 + DO ;1SUB#4 <- #42984$#2720 + DO .4 <- #16 + DO (100) NEXT + + PLEASE GIVE UP + +(100) PLEASE STASH .1 + .2 + .3 + .5 + PLEASE DO ,9 <- .4 + DO .1 <- #0 + PLEASE COME FROM (101) + DO .2 <- .1 + DO .3 <- #4 + PLEASE COME FROM (103) + DO .5 <- '?".1~.3"$#1'~#3 + DO .1 <- '?.1$.3'~'#0$#65535' + DO (104) NEXT +(103) DO .3 <- !3$#0'~'#32767$#1' +(104) DO (1001) NEXT + PLEASE FORGET #1 + DO :1 <- ;1SUB'.1~#65532' + DO ,9SUB'".2$#1"~"#65532$#3"' <- :1~'#43690$#0' + DO ,9SUB'".2$#2"~"#65532$#3"' <- :1~'#21845$#0' + DO ,9SUB'".2$#3"~"#65532$#3"' <- :1~'#0$#43690' + DO ,9SUB.1 <- :1~'#0$#21845' + DO .5 <- '?"'#65535~"'?.4$.1'~'#0$#65532'"'~#1"$#1'~#3 +(101) DO (102) NEXT +(102) DO (1001) NEXT + PLEASE READ OUT ,9 + PLEASE RETRIEVE .1 + .2 + .3 + .5 + PLEASE RESUME #2 + +(200) DO ,3001SUB#1 <- #196 + DO (3099) NEXT + PLEASE RESUME #1 + +(220) DO ,3001SUB#1 <- #196 + DO (3090) NEXT + DO .2 <- #60 + DO (3001) NEXT + PLEASE READ OUT ,2 + DO ,3001SUB#1 <- #196 + PLEASE RESUME #1 + + PLEASE NOTE THE SMALL SUBSET OF THE SYSTEM LIBRARY + +(1000) DO STASH .1 + .2 + .5 + .6 + DO (1004) NEXT +(1004) PLEASE FORGET #1 + DO .3 <- '?.1$.2'~'#0$#65535' + DO .6 <- '&.1$.2'~'#0$#65535' + DO .5 <- '?"!6~.6'~#1"$#1'~#3 + DO (1003) NEXT + DO .1 <- .3 + DO .2 <- !6$#0'~'#32767$#1' + DO (1004) NEXT +(1003) DO (1001) NEXT + PLEASE RETRIEVE .1 + .2 + .5 + .6 + PLEASE RESUME #2 +(1001) DO RESUME .5 + +(1010) DO STASH .1 + .2 + DO .3 <- .1 + DO .1 <- '?.2$#65535'~'#0$#65535' + DO (1020) NEXT + PLEASE DO .2 <- .3 + PLEASE DO (1000) NEXT + DO RETRIEVE .1 + .2 + PLEASE RESUME #1 + +(1020) DO STASH .2 + .3 + DO .2 <- #1 + PLEASE DO (1021) NEXT +(1021) DO FORGET #1 + DO .3 <- "?!1~.2'$#1"~#3 + PLEASE DO .1 <- '?.1$.2'~'#0$#65535' + DO (1022) NEXT + DO .2 <- !2$#0'~'#32767$#1' + DO (1021) NEXT +(1023) PLEASE RESUME .3 +(1022) DO (1023) NEXT + PLEASE RETRIEVE .2 + .3 + PLEASE RESUME #2 + + PLEASE USE A SUBSET OF THE AUTHORIZED CHANNELS + +(2030) DO STASH .1 + .5 + DO .3 <- #0 + DO .5 <- '?"!2~.2'~#1"$#1'~#3 + PLEASE DO (2031) NEXT + DO .4 <- #1 + PLEASE DO (2033) NEXT +(2033) DO FORGET #1 + DO .5 <- '?".2~#32768"$#2'~#3 + DO (2032) NEXT + DO .2 <- !2$#0'~'#32767$#1' + PLEASE DO .4 <- !4$#0'~'#32767$#1' + DO (2033) NEXT +(2032) DO (1001) NEXT +(2036) PLEASE FORGET #1 + DO .5 <- '?.1$.2'~'#0$#65535' + DO .5 <- '?"'&"!2~.5'~'"?'?.5~.5'$#32768"~"#0$#65535"'"$ + ".5~.5"'~#1"$#2'~#3 + DO (2034) NEXT + DO .5 <- .3 + DO (1010) NEXT + PLEASE DO .1 <- .3 + DO .3 <- 'V.4$.5'~'#0$#65535' + DO (2035) NEXT +(2034) PLEASE DO (1001) NEXT +(2035) DO FORGET #1 + DO .5 <- "?'.4~#1'$#2"~#3 + DO (2031) NEXT + DO .2 <- .2~#65534 + DO .4 <- .4~#65534 + PLEASE DO (2036) NEXT +(2031) DO (1001) NEXT + PLEASE DO .4 <- .1 + PLEASE RETRIEVE .1 + .5 + PLEASE RESUME #2 + +(3000) DO STASH .2 + .3 + .5 + DO .2 <- ,3000SUB#1 + PLEASE WRITE IN ,3000 + DO .1 <- ,3000SUB#1 + DO .5 <- '?".1~#256"$#2'~#3 + DO (3008) NEXT + DO (1000) NEXT + DO .1 <- .3~#255 + DO ,3000SUB#1 <- .1 + DO (3009) NEXT +(3008) DO (1001) NEXT +(3009) DO RETRIEVE .2 + .3 + .5 + PLEASE RESUME #2 + +(3001) DO STASH .1 + .3 + DO .1 <- ,3001SUB#1 + DO (1010) NEXT + DO ,3001SUB#1 <- .3~#255 + PLEASE READ OUT ,3001 + DO ,3001SUB#1 <- .2 + DO .1 <- .2 + DO RETRIEVE .1 + .3 + PLEASE RESUME #1 + +(3090) PLEASE ABSTAIN FROM (3097) +(3099) PLEASE STASH .1 + .2 + .3 + .4 + DO .2 <- #256 + PLEASE STASH .2 + DO (3091) NEXT + DO (3095) NEXT + DO .2 <- #80 +(3097) DO (3001) NEXT + PLEASE REINSTATE (3097) + PLEASE RETRIEVE .1 + .2 + .3 + .4 + PLEASE RESUME #1 +(3098) PLEASE RESUME '?"!1~.1'~#1"$#2'~#3 +(3091) DO COME FROM (3092) + DO .2 <- #10 + DO (2030) NEXT + DO .2 <- .4 + PLEASE STASH .2 + DO .1 <- .3 +(3092) DO (3098) NEXT + +(3095) DO COME FROM (3094) + PLEASE RETRIEVE .2 + DO (3093) NEXT + DO .2 <- .2$#3 + DO .2 <- !2~#15'$!2~#240' + DO .2 <- !2~#15'$!2~#240' +(3094) DO (3001) NEXT +(3093) PLEASE RESUME '?".2~#256"$#1'~#3 + +(3990) PLEASE DO ,3000 <- #1 + DO ,3000SUB#1 <- #0 + PLEASE DO ,3001 <- #1 + DO ,3001SUB#1 <- #0 + PLEASE RESUME #1 diff --git a/src/Makefile b/src/Makefile index 3f41143..b2430c4 100644 --- a/src/Makefile +++ b/src/Makefile @@ -8,7 +8,8 @@ # all over creation behind your back. # (/dev/null may be another good choice :-)) -DVMT=/home2/esr/WWW/intercal-0.15 +DVMT=~/WWW/intercal-0.16 +#DVMT=/usr/local BINDIR = $(DVMT)/bin INCDIR = $(DVMT)/lib @@ -69,15 +70,9 @@ libick.a: cesspool.o lose.o fiddle.o arrgghh.o -ranlib libick.a install: all - -mkdir $(BINDIR); rm -f $(BINDIR)/* cp ick $(BINDIR) - -mkdir $(INCDIR) - (cd $(INCDIR); rm -f lose.h abcess.h fiddle.h ick-wrap.c) cp lose.h abcess.h fiddle.h ick-wrap.c $(INCDIR) - -mkdir $(LIBDIR) - (cd $(LIBDIR); rm -f libick.a syslib.i) - cp libick.a ../pit/lib/syslib.i $(LIBDIR) - -ranlib $(LIBDIR)/libick.a + cp libick.a ../pit/lib/syslib.i ../pit/lib/syslib.?i $(LIBDIR) clean: rm -f yacc.* y.tab.* y.output *~ *.[oa] lexer.c ick.c lextest ick diff --git a/src/cesspool.c b/src/cesspool.c index 559bd3f..b4c5d52 100644 --- a/src/cesspool.c +++ b/src/cesspool.c @@ -90,10 +90,13 @@ unsigned int pin(void) if (fgets(buf, BUFSIZ, stdin) == (char *)NULL) lose(E562, lineno, (char *)NULL); - buf[strlen(buf)-1] = '\0'; + n = strlen(buf) - 1; + if (buf[n-1] == '\r') + --n; + buf[n] = '\0'; if(wimp_mode) { - result = atoi(buf); + result = (unsigned int)strtoul(buf, (char **)NULL, 10); n = 1; } else @@ -318,6 +321,8 @@ void binout(unsigned int type, array *a) c = (c & 0x33) << 2 | (c & 0xcc) >> 2; c = (c & 0x55) << 1 | (c & 0xaa) >> 1; putchar(c); + if (c == '\n') + fflush(stdout); } } diff --git a/src/feh.c b/src/feh.c index 5bd0a00..3833be7 100644 --- a/src/feh.c +++ b/src/feh.c @@ -79,14 +79,31 @@ unsigned int intern(int type, int index) if (index < 1 || index > 65535) lose(E200, yylineno, (char *)NULL); + if (!oblist) + { + /* initialize oblist and obdex */ + oblist = malloc(ALLOC_CHUNK * sizeof(atom)); + if (!oblist) + lose(E778, yylineno, (char *)NULL); + obdex = oblist; + obcount = ALLOC_CHUNK; + } + /* if it's already on the oblist, return its intindex */ for (x = oblist; x < obdex; x++) if (x->type == type && x->extindex == index) return(x->intindex); /* else we must intern a new symbol */ - if (obdex >= oblist + MAXVARS) - lose(E333, yylineno, (char *)NULL); + if (obdex >= oblist + obcount) + { + obcount += ALLOC_CHUNK; + x = realloc(oblist, obcount * sizeof(atom)); + if (!x) + lose(E333, yylineno, (char *)NULL); + obdex = x + (obdex - oblist); + oblist = x; + } obdex->type = type; obdex->extindex = index; if (type == ONESPOT) @@ -122,7 +139,12 @@ void checklabel(int label) void treset(void) { - memset(tuples, '\0', sizeof(tuple) * MAXLINES); + tuplecount = 0; + if (tuples) + { + free(tuples); + tuples = NULL; + } nonespots = ntwospots = ntails = nhybrids = 0; obdex = oblist; lineno = 0; @@ -131,13 +153,21 @@ void treset(void) tuple *newtuple(void) /* allocate and zero out a new expression tuple */ { - if (lineno >= MAXLINES) + if (lineno >= tuplecount) { - lose(E666, yylineno, (char *)NULL); - return NULL; + tuplecount += ALLOC_CHUNK; + if (tuples) + tuples = realloc(tuples, tuplecount * sizeof(tuple)); + else + tuples = malloc(tuplecount * sizeof(tuple)); + if (!tuples) + { + lose(E666, yylineno, (char *)NULL); + return NULL; + } + memset(tuples + lineno, 0, (tuplecount - lineno) * sizeof(tuple)); } - else - return(tuples + lineno++); + return(tuples + lineno++); } /************************************************************************* @@ -259,33 +289,6 @@ void codecheck(void) * **************************************************************************/ -#define ISCONSTANT(np, v) ((np->opcode == MESH || np->opcode == MESH32) && np->constant == v) - -static void rfree(node *np) -/* recursively free the given node and all nodes underneath */ -{ - if (np->lval != (node *)NULL) - rfree(np->lval); - if (np->rval != (node *)NULL) - rfree(np->rval); - free(np); -} - -static int requal(node *mp, node *np) -/* do two node trees represent the same expression? */ -{ - if (mp == (node *)NULL && np == (node *)NULL) - return(TRUE); - else if (mp == (node *)NULL || np == (node *)NULL) - return(FALSE); - else if (mp->opcode != np->opcode || mp->constant != np->constant) - return(FALSE); - else if (!requal(mp->lval, np->lval) || !requal(mp->lval, np->lval)) - return(FALSE); - else - return(TRUE); -} - void optimize(node *np) { node *mingleop, *op; @@ -374,28 +377,6 @@ void optimize(node *np) * Less trivial stuff begins here */ - /* equality test by XOR */ - if (np->opcode == TESTNZ && np->rval->opcode == XOR) - { - node *tp = np->rval; - - np->opcode = EQUALS; - np->lval = tp->lval; - np->rval = tp->rval; - free(np->rval); - } - - /* check for non-zeroness test */ - if (np->opcode == SELECT && ISCONSTANT(np->rval, 1) && requal(np->lval->rval, np->lval->lval)) - { - rfree(np->rval); - np->rval = np->lval->rval; - rfree(np->lval->lval); - np->lval = (node *)NULL; - np->opcode = TESTNZ; - np->width = 16; - } - /* following optimizations only work in binary */ if (Base != 2) return; @@ -424,7 +405,7 @@ void optimize(node *np) } /* recognize idioms for ~ */ - if (np->opcode == XOR) + if (np->opcode == C_XOR) { if (np->rval->width == 16 && np->lval->opcode == MESH &&np->lval->constant == 0xffff) @@ -437,8 +418,8 @@ void optimize(node *np) && np->rval->opcode == MESH && np->rval->constant == 0xffff) { np->opcode = C_NOT; - np->rval = np->lval; free(np->rval); + np->rval = np->lval; } if (np->rval->width == 32 @@ -452,8 +433,8 @@ void optimize(node *np) && np->rval->opcode == MESH32 && np->rval->constant == 0xffffffffL) { np->opcode = C_NOT; - np->rval = np->lval; free(np->rval); + np->rval = np->lval; } } } @@ -629,14 +610,6 @@ static void prexpr(node *np, FILE *fp) (void) fprintf(fp, ")"); break; - case EQUALS: - (void) fprintf(fp, "("); - prexpr(np->lval, fp); - (void) fprintf(fp, " == "); - prexpr(np->rval, fp); - (void) fprintf(fp, ")"); - break; - case FIN: if (Base < 3) lose(E997, emitlineno, (char *)NULL); @@ -676,12 +649,6 @@ static void prexpr(node *np, FILE *fp) break; /* cases from here down are generated by the optimizer */ - case TESTNZ: - (void) fprintf(fp, "("); - prexpr(np->rval, fp); - (void) fprintf(fp, " != 0)"); - break; - case C_AND: (void) fprintf(fp, "("); prexpr(np->lval, fp); @@ -709,7 +676,10 @@ static void prexpr(node *np, FILE *fp) case C_NOT: (void) fprintf(fp, "(~"); prexpr(np->rval, fp); - (void) fprintf(fp, ")"); + if (np->rval->width == Small_digits) + (void) fprintf(fp, " & Max_small)"); + else + (void) fprintf(fp, " & Max_large)"); break; } @@ -727,6 +697,9 @@ static char *nice_text(char *texts[], int lines) lines = 1; for (cp = buf, i = 0 ; i < lines ; ++i) { if (i) { + (*cp++) = '\\'; + (*cp++) = 'n'; + (*cp++) = '\\'; (*cp++) = '\n'; (*cp++) = '\t'; } @@ -781,17 +754,6 @@ void emit(tuple *tn, FILE *fp) emitlineno = yylineno; (void) fprintf(fp, " lineno = %d;\n", emitlineno); - /* emit random compiler bug */ - if (!nocompilerbug) - { -#ifdef USG - if ((lrand48() & 127) == 127) -#else - if ((rand() & 127) == 127) -#endif - (void) fprintf(fp, " lose(E774, lineno, (char *)0);\n"); - } - /* emit conditional-execution prefixes */ if (tn->type != COME_FROM) emit_guard(tn, fp); diff --git a/src/ick.h b/src/ick.h index 9508230..87164e2 100644 --- a/src/ick.h +++ b/src/ick.h @@ -10,17 +10,14 @@ typedef int bool; #define TRUE 1 #define FALSE 0 -/* - * We choose this value for maximum number of possible source lines on - * the theory that no human mind could grok more lines of INTERCAL than - * this and still retain any vestige of sanity. - */ -#define MAXLINES 1000 +#define ALLOC_CHUNK 256 /* - * Similarly for maximum number of variables - */ + * We choose this value for maximum number of possible variables on + * the theory that no human mind could grok a more complex INTERCAL + * program than this and still retain any vestige of sanity. #define MAXVARS 100 + */ /* * Maximum supported statement types; should be equal to (COME_FROM - GETS + 1) @@ -66,16 +63,18 @@ typedef struct } assoc; -extern atom oblist[MAXVARS], *obdex; -extern int nonespots, ntwospots, ntails, nhybrids; +extern atom *oblist, *obdex; +extern int obcount, nonespots, ntwospots, ntails, nhybrids; -extern tuple tuples[MAXLINES]; +extern tuple *tuples; +extern int tuplecount; extern char *enablers[MAXTYPES]; extern assoc vartypes[]; /* the lexical analyzer keeps copies of the source logical lines */ -extern char *textlines[MAXLINES]; +extern char **textlines; +extern int textlinecount; extern int yylineno; /* compilation options */ diff --git a/src/ick.y b/src/ick.y index 6025956..0752bb8 100644 --- a/src/ick.y +++ b/src/ick.y @@ -90,7 +90,7 @@ static tuple *splat(void); * will not conflict with the other tokens. It is important that * WHIRL through WHIRL5 be a continuous sequence. */ -%token SPLATTERED TESTNZ C_AND C_OR C_XOR C_NOT EQUALS AND OR XOR FIN MESH32 +%token SPLATTERED C_AND C_OR C_XOR C_NOT AND OR XOR FIN MESH32 %token WHIRL WHIRL2 WHIRL3 WHIRL4 WHIRL5 %type expr varlist variable constant lvalue inlist outlist diff --git a/src/lexer.l b/src/lexer.l index 5005988..67b6ee2 100644 --- a/src/lexer.l +++ b/src/lexer.l @@ -46,7 +46,8 @@ int yylineno = 1; YYSTYPE yylval; #endif /* MAIN */ -char *textlines[MAXLINES]; +char **textlines = NULL; +int textlinecount = 0; int politesse = 0; int stbeginline = 0; @@ -93,7 +94,7 @@ int getc(FILE *fp) else if (backflag) /* converting ctrl-H (backspace) to two chars "^H" */ { backflag = FALSE; - /* *lineptr++ = '\010'; */ + /* *lineptr++ = '\b'; */ return('H'); } else @@ -123,10 +124,10 @@ int getc(FILE *fp) bangflag = TRUE; return(c = '\''); } - else if (c == '\010') /* convert ctrl-H (backspace) to + else if (c == '\b') /* convert ctrl-H (backspace) to two chars "^" and "H" so lex can take it */ { - *lineptr++ = '\010'; + *lineptr++ = '\b'; backflag = TRUE; return(c = '^'); } @@ -134,7 +135,21 @@ int getc(FILE *fp) { *lineptr = '\0'; lineptr = linebuf; - textlines[yylineno] = strcpy((char *)malloc(1+strlen(linebuf)),linebuf); + if (yylineno >= textlinecount) + { + textlinecount += ALLOC_CHUNK; + if (textlines) + textlines = realloc(textlines, + textlinecount * sizeof(char*)); + else + textlines = malloc(textlinecount * sizeof(char*)); + if (!textlines) + lose(E666, yylineno, (char *)NULL); + } + textlines[yylineno] = malloc(1 + strlen(linebuf)); + if (!textlines[yylineno]) + lose(E666, yylineno, (char *)NULL); + strcpy(textlines[yylineno], linebuf); #ifdef YYLINENO_BY_HAND yylineno++; #endif /* YYLINENO_BY_HAND */ @@ -198,7 +213,6 @@ V {yylval.numval = OR; return(UNARY);} DO {SETLINENO; return(DO);} PLEASE {SETLINENO; politesse++; return(DO);} -DO{W}PLEASE {SETLINENO; politesse++; return(DO);} PLEASE{W}DO {SETLINENO; politesse++; return(DO);} NOT {return(NOT);} N\'T {return(NOT);} diff --git a/src/lose.h b/src/lose.h index 634a6b1..3c24648 100644 --- a/src/lose.h +++ b/src/lose.h @@ -11,7 +11,7 @@ * Analog magazine sometime in 1983 and later anthologized in the author's * "Infinite Dreams" (Ace 1985). */ -/* An undecodable statement has been encountered in the course of execution."*/ +/* An undecodable statement has been encountered in the course of execution. */ #define E000 "000 %s\n\ ON THE WAY TO %d\n" /* An expression contains a syntax error. */ diff --git a/src/perpetrate.c b/src/perpetrate.c index a5fde21..03849fb 100644 --- a/src/perpetrate.c +++ b/src/perpetrate.c @@ -64,14 +64,21 @@ static bool dooptimize; /* do optimizations? (controlled by -O) */ static bool clockface; /* set up output to do IIII for IV */ #define SKELETON "ick-wrap.c" -#define SYSLIB "syslib.i" +#define SYSLIB "syslib" /* numeric base defaults, exported to other files */ -int Base = 2; -int Small_digits = 16; -int Large_digits = 32; -unsigned int Max_small = 0xffff; -unsigned int Max_large = 0xffffffff; + +#define DEFAULT_BASE 2 +#define DEFAULT_SMALL_DIGITS 16 +#define DEFAULT_LARGE_DIGITS 32 +#define DEFAULT_MAX_SMALL 0xffffL +#define DEFAULT_MAX_LARGE 0xffffffffL + +int Base; +int Small_digits; +int Large_digits; +unsigned int Max_small; +unsigned int Max_large; int lineno; /* after yyparse, this is the total number of statements */ @@ -83,10 +90,12 @@ static unsigned int maxsmalls[8] = static char *compiler; -atom oblist[MAXVARS], *obdex; +atom *oblist = NULL, *obdex; +int obcount = 0; int nonespots, ntwospots, ntails, nhybrids; -tuple tuples[MAXLINES]; +tuple *tuples = NULL; +int tuplecount = 0; static void abend(int signim) { @@ -113,11 +122,11 @@ int main(int argc, char *argv[]) char buf[BUFSIZ], buf2[BUFSIZ], *chp, *strrchr(); tuple *tp; atom *op; - int c; + int c, i; char *includedir, *libdir, *getenv(); FILE *ifp, *ofp; - int maxabstain, nextcount; - bool needsyslib; + int maxabstain, nextcount, bugline; + bool needsyslib, firstfile; if (!(includedir = getenv("ICKINCLUDEDIR"))) includedir = ICKINCLUDEDIR; @@ -183,7 +192,7 @@ int main(int argc, char *argv[]) lose(E999, 1, (char *)NULL); buf[strlen(buf) - 2] = '\0'; - for (; optind < argc; optind++) + for (firstfile = TRUE; optind < argc; optind++, firstfile = FALSE) { if (freopen(argv[optind], "r", stdin) == (FILE *)NULL) lose(E777, 1, (char *)NULL); @@ -196,10 +205,21 @@ int main(int argc, char *argv[]) } *chp++ = '\0'; + /* wwp: reset the base variables to defaults, because if the */ + /* sourcefile has extension .i they will not be reset in the */ + /* following chunk of code. but i don't want to modify the */ + /* following chunk of code because i think it is very clever; */ + /* grabs the base on the first pass, then validates the rest */ + /* of the extension on the second. */ + Base = DEFAULT_BASE; + Small_digits = DEFAULT_SMALL_DIGITS; + Large_digits = DEFAULT_LARGE_DIGITS; + Max_small = DEFAULT_MAX_SMALL; + Max_large = DEFAULT_MAX_LARGE; + /* determine the file type from the extension */ while (strcmp(chp,"i")) { - long strtol(); Base = strtol(chp,&chp,10); if (Base < 2 || Base > maxbase) lose(E998, 1, (char *)NULL); @@ -218,6 +238,17 @@ int main(int argc, char *argv[]) treset(); politesse = 0; + /* reset the lex/yacc environment */ + if (!firstfile) + { +#ifdef NEED_YYRESTART + yyrestart(stdin); +#endif /* NEED_YYRESTART */ +#ifdef YYLINENO_BY_HAND + yylineno = 1; +#endif /* YYLINENO_BY_HAND */ + } + /* compile tuples from current input source */ yyparse(); @@ -225,7 +256,7 @@ int main(int argc, char *argv[]) * Miss Manners lives. */ if (lineno > 2) - if (politesse == 0 || lineno / politesse > 5) + if (politesse == 0 || (lineno - 1) / politesse >= 5) lose(E079, yylineno, (char *)NULL); else if (lineno / politesse < 3) lose(E099, yylineno, (char *)NULL); @@ -253,7 +284,10 @@ int main(int argc, char *argv[]) needsyslib = TRUE; } if ( needsyslib ) { - (void) sprintf(buf2, "%s/%s", ICKLIBDIR, SYSLIB); + if (Base == 2) + (void) sprintf(buf2, "%s/%s.i", libdir, SYSLIB); + else + (void) sprintf(buf2, "%s/%s.%di", libdir, SYSLIB, Base); if ( freopen(buf2, "r", stdin) == (FILE*) NULL ) { lose(E127, 1, (char*) NULL); } @@ -284,6 +318,17 @@ int main(int argc, char *argv[]) || tp->type == FORGET || tp->type == RESUME) optimize(tp->u.node); + /* decide if and where to place the compiler bug */ +#ifdef USG + if (!nocompilerbug && lrand48() % 10 == 0) + bugline = (int)(lrand48() % lineno); +#else + if (!nocompilerbug && rand() % 10 == 0) + bugline = rand() % lineno; +#endif + else + bugline = -1; + /* set up the generated C output file name */ (void) strcpy(buf, argv[optind]); (void) strcat(buf, ".c"); @@ -331,8 +376,6 @@ int main(int argc, char *argv[]) maxabstain++; if (maxabstain) { - int i; - (void) fprintf(ofp, "#define UNKNOWN\t\t0\n"); i = 0; for (; i < (int)(sizeof(enablers)/sizeof(char *)); i++) @@ -412,8 +455,13 @@ int main(int argc, char *argv[]) break; case 'G': /* degenerated code */ - for (tp = tuples; tp->type; tp++) + for (tp = tuples, i = 0; tp->type; tp++, i++) + { emit(tp, ofp); + if (i == bugline) + (void) fprintf(ofp, " lose(E774, lineno, " + "(char *)NULL);\n"); + } break; case 'H': /* dispatching for resumes */ diff --git a/src/sizes.h b/src/sizes.h index f3c49a8..a344bc7 100644 --- a/src/sizes.h +++ b/src/sizes.h @@ -1,4 +1,4 @@ -/* sizes.h -- constants defining the numeric base for Intercal variations */ +/* sizes.h -- constants defining the numeric base for INTERCAL variations */ extern int Base; extern int Small_digits; diff --git a/website/index.html b/website/index.html index dc18cd1..a399afa 100644 --- a/website/index.html +++ b/website/index.html @@ -6,14 +6,16 @@ INTERCAL Resource Page -

This is the INTERCAL Resources Page.

+

This is the INTERCAL Resources Page.

+Back to Eric Raymond's Home Page. +
Beware! If you aren't a hard-core hacker, you'd best surf right back where you came from now. Nothing but twisted technical yuks and an inexorable descent into brain-sucking obsession awaits beyond this point. You have been warned. -

Abandon All Sanity, Ye Who Enter Here

+

Abandon All Sanity, Ye Who Enter Here

So, you think you've seen it all, eh?

@@ -41,7 +43,7 @@ of technomasochists.

INTERCAL. Now you, too, can be a part of the madness.

-

INTERCAL Resources

+

INTERCAL Resources

Documentation

@@ -51,6 +53,13 @@ version of the Revised INTERCAL Manual here. Postscript is recommended, as the manual now includes figures and diagrams until recently unseen by any but the small handful with paper copies.

+Alexander Garret wrote a paper on INTERCAL +for his Programming Languages: Theory and Design class. Alexander +writes: "The obvious choice was INTERCAL (I'm still quite surprised +that I'm the only one who picked it -- most people did +Java??). Anyway, it was not favourably received..." We have corrected +one typo (misspelling of "Malvernite") in this copy.

+

Implementations

You can download the latest version of the INTERCAL has even shown up once in the print media. Here's a transcript of an article by Charles Stross., -

Related Links

+

Related Links

If INTERCAL interests you, you may want to check out the Jargon File and the Eric S. Raymond, who also maintains a large collection of freeware you may find stimulating.


+Back to Eric Raymond's Home Page.

+

Eric S. Raymond <esr@snark.thyrsus.com>
-- 2.43.0