о╚0:Бе600002Х8000:ML│96:KK│MLл24:М L$(KK)ДQ│ Ж(&HC000):Т &HC000,0:Е  Ж(&HC000)│0 з CC│3:WW│80:NL│23 :Д CC│1:WW│32:NL│15ЩТ &HC000,Q:PD│м2┤Е Q│68 з DN│1 :Д DN│м1╒Ю:З" super list":ЗOЗ" THIS PROGRAM WILL LET YOU VIEW AND/OR PRINT ANY ASCII TEXT FILE. (LIKE A DOCUMENT OR INSTRUCTION FILE.)Й З" USE ? DURING VIEW MODE FOR MORE HELP ON COMMANDS."0!З" AUTOMATICALLY SENSES DISK/TAPE AND COCO 2/COCO 3 MODES.":З:З" THE DOCUMENTATION FILES ON THIS DISK ARE FRTHDOC1.TXT FRTHDOC2. TXT FRTHDOC3.TXT + FTHFIX.TXT":ЗH"╗ Й" FILENAME? ";F$](DF│0:Щ"I",#DN,F$f*LP│1r,Бж 1000А IF EOF EXIT ENDIF CHRPTR @ C@ D = IF INSERT ENDIF CHRPTR @ C! RT-ARR 0 ; : DUMMY ; : RETN-ED 1 XFLAG ! ; : EXIT-ED 1 XFLAG ! 0 ZFLAG ! ; : REST-ED 1 XFLAG ! STARTUP PRTPAG ; CASE: O-OPTION DUMMY RETN-ED EXIT-ED DISKSAV CASSAV REST-ED ; : WRAPUP CLS ." ENTER OPTION" CR ." 1 = RETURN TO EDIT" CR ." 2 = EXIT PROGRAM" CR ." 3 = SAVE TO DISK" CR ." 4 = SAVE TO CASSETTE" CR ." 5 = RESTART PROGRAM" CR #IN CR O-OPTION ; : REDIT 1 ZFLAG ! BEGIN PRTPAG 0 XFLAG ! BEGIN INKEY CONTROL DROP XFLAG @ UNTIL REPEAT 0 XFLAG ! BEGIN WRAPUP XFLAG @ UNTIL REPEAT ZFLAG @ WHILE REPEAT ; : EDIT STARTUP REDIT ; : .S DUP . ; : L PRTPAG E 0 PTC ; : LLIST ." READY PRINTER " KEY 3 = IF EXIT ENDIF -2 DEVNUM C! ENDTXT @ 1- BUFFER DO I C@ EMIT LOOP 0 DEVNUM C! ; : .R SWAP 0 <# #S #> ROT OVER - DUP 1- 0< IF CLEAR DROP ." BR " EXIT ENDIF SPACES TYPE ; EDIT L PRTPAG E 0 PTC ; : LLIST ." READY PRINTER "                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Ў& x┌ И&ВЮ:Х2048&AМЗ@224,"STANDBY FOR COLOR DIRECTORY 1.0"&iЦЗ@322,"SELECT FILE WITH ARROW KEYS"&ХаЗ@352,"[ENTER] TO DUMP FILE TO PRINTER"&ккА I│1 е 1000:Л I&╣┤АX│512е541&┴╛НA$&╘╚ТX, Й("&H"лA$)&┌╥Л&ч▄╣ Г0│512&√цЙ "DRIVE NO.";Z'ш╧ Z'ЁF│ г(Z)'/·МA$(68):Y│1:P1│1:PO│4:T│247';АX│3е11'_▀ Z,17,X,A$,B$:C$│A$л О(B$,127)'jАN│0е7'Ь"A$(Y)│ Р(C$,Nн32л1,8)л" "л Р(C$,Nн32л9,3)л" "'─,R│ К(A$(Y)):ЕR│255 з A$(Y)│"":Бе360'э6A$(Y)│A$(Y)л Л( Ж(1547лNн32)л48)л" "((@Е  Ж(1548лNн32)│0 з A$(Y)│A$(Y)л"B" :Д A$(Y)│A$(Y)л"A"(BJЕR│0 з A$(Y)│"":Бе350(LTY│Yл1(U^ЛN,X(АhP2│ Б((Yм1)о10):ЕP2┤(Yм1)о10 з P2│P2л1(ЖrЮ(й|Зд4)"COLOR DISK DIRECTORY 1.0"(┴ЖЗд10)"DISK DRIVE";Z)РТ341,255:Т342,255:З@65,"USED";68мF;"FREE";F;" PAGE"P1"OF"P2:З)ЪH│(P1м1)н10л1)$дАX│H е Hл9);оЕA$(X)│""з З:Бе450)I╕Зд8)A$(X))O┬Л)М╠Т341,255:Т342,255:K│POн32л8:Т529,&H80:A│ Г0(K):Т529,&H8B)б╓E│(P1м1)н10лPOм3* рЕ Ж(341)│T ░ PO│4 ░ P1▓1 з P1│P1м1:PO│13:A│ Г0(K):Бе400 :Д Е  Ж(341)│T ░ PO▓4 з A│ Г0(K):PO│POм1:Бе460*ВъЕ Ж(342)│T ░ PO┤13 ░ E┤Yм1 з A│ Г0(K):PO│POл1:Бе460 :Д Е  Ж (342)│T ░ P1┤P2 ░ PO│13 з P1│P1л1:PO│4:A│ Г0(K):Бе400*ШЇЕ  Т│ Л(13) з 520*в■Бе480*╚ Р(A$(E),9,1)│".":T$│ О(A$(E),12)*╥Бе600*▄&Бе480+20Ж BD,B3,ED,C3,4,0,1F,1,C3,0,10,ED,8D,0,D,A6,84,8B,40,A7,80,AC,8D,0,3,26,F4,39,0,0+lXЕ  П(A$(E),1)│"B"з З"NOT AN ASCII FILE":а 1,30:Бе 370+Г[Й"READY PRINTER";V+Т\Ю:З@233,T$+гbЩ"D",#1,T$,1+┤l╨ #1,1  з A$+─vА M│1е е(1)+═А─ #1+┌ФЗ#м2,A$;+т╝Л M+ы╞Ъ #1+ї╨Бе370C3,0,10                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 HEX 1000 CONSTANT BUFFER 4000 CONSTANT BUFEND 49 CONSTANT MODE-INPUT 4F CONSTANT MODE-OUTPUT 0FF CONSTANT ASCII-DATA 88 CONSTANT CSRAD 153 CONSTANT KT-CLEAR 0 VARIABLE ENDTXT 0 VARIABLE PAGPTR 0 VARIABLE BOTPTR 0 VARIABLE LINPTR 0 VARIABLE CHRPTR 0 VARIABLE XFLAG 0 VARIABLE ZFLAG : PRT@ CSRAD ! ; : CASE: SWAP 2* + @ EXECUTE ; : DELAY 20 0 DO LOOP ; : TEST-CLEAR KT-CLEAR C@ 40 AND 0= ; : NEWFILE 20 BUFFER C! BUFFER 1+ ENDTXT ! ; : CASSLOAD MODE-INPUT COPEN BUFFER ENDTXT ! BEGIN CREAD DUP 0= UNTIL DUP EMIT ENDTXT @ DUP 1+ ENDTXT ! C! REPEAT CCLOSE ; : CASSAV MODE-OUTPUT COPEN ENDTXT @ 1- BUFFER DO I C@ CWRITE I C@ EMIT DELAY LOOP CCLOSE ; : DISKLOAD ASCII-DATA MODE-INPUT 1 ." FILENAME ?" WORD OPEN BUFFER ENDTXT ! BEGIN 1 READ DUP 0= UNTIL DUP EMIT ENDTXT @ DUP 1+ ENDTXT ! C! REPEAT 1 CLOSE ; : DISKSAV ASCII-DATA MODE-OUTPUT 1 ." FILENAME ?" WORD OPEN ENDTXT @ 1- BUFFER DO I C@ EMIT I C@ 1 WRITE LOOP 1 CLOSE ; CASE: I-OPTION NEWFILE NEWFILE DISKLOAD CASSLOAD ; : STARTUP CLS ." PROGRAM EDITOR" CR CR ." SOURCE FILE" CR ." 1 = NEW FILE" CR ." 2 = DISK FILE" CR ." 3 = TAPE FILE" CR #IN CR I-OPTION BUFFER PAGPTR ! D ENDTXT @ C! ; : FIND-CR CHRPTR @ DUP BUFFER < IF DROP EXIT ENDIF BEGIN 1- DUP DUP BUFFER < SWAP C@ D = OR UNTIL REPEAT CHRPTR ! ; : EOF CSRAD @ FF EMIT FF EMIT CSRAD ! ; : PRTLIN PRT@ LINPTR @ 31 0 DO DUP C@ DUP EMIT 0D = IF LEAVE ENDIF 1+ LOOP LINPTR ! ; : ONE-LINE DO LINPTR @ ENDTXT @ 1- < IF I PRTLIN LINPTR @ BOTPTR ! ELSE I PRT@ CR ENDIF 20 LOOP+ 5E0 20 60 FILL ; : PRTPAG PAGPTR @ LINPTR ! 5C0 400 ONE-LINE PAGPTR @ CHRPTR ! 0 0 PTC ; : RE-PAGE CHRPTR @ 1+ DUP LINPTR ! CSRAD @ 5E0 AND 5C0 OVER ONE-LINE CSRAD ! CHRPTR ! ; : UP-ROLL 400 420 1E0 IF CSRAD @ D EMIT 20 - CSRAD ! ENDIF ; : RT-ARR CHRPTR @ DUP ENDTXT @ 1- > IF DROP EOF EXIT ENDIF DUP 1+ CHRPTR ! C@ EMIT ; : CTL-RT-ARR CHRPTR @ ENDTXT @ 1- > IF DROP EOF EXIT ENDIF INSERT 20 CHRPTR @ C! SAME-LINE ; : CTL-LF-ARR CHRPTR @ C@ D = IF EXIT ELSE DELETE ENDIF ; : SH-RT-ARR BEGIN CHRPTR @ DUP ENDTXT @ 1- > IF DROP EOF EXIT ENDIF DUP C@ EMIT 1+ DUP CHRPTR ! C@ D = UNTIL REPEAT CHECK ; : DN-ARR BEGIN CHRPTR @ DUP ENDTXT @ 1- > IF DROP EOF EXIT ENDIF DUP 1+ CHRPTR ! C@ DUP EMIT D = UNTIL REPEAT ; : UP-ARR CHRPTR @ BUFFER = IF EXIT ENDIF CSRAD @ 420 < IF UP-ROLL ENDIF FIND-CR FIND-CR CSRAD @ 20 - CSRAD ! THIS-LINE ; : LF-ARR CHRPTR @ DUP BUFFER = IF DROP EXIT ENDIF 1- C@ D = IF UP-ARR ELSE -1 CHRPTR +! CSRAD @ 1- DUP CSRAD ! CHRPTR @ C@ EMIT CSRAD ! ENDIF ; : SH-LF-ARR FIND-CR THIS-LINE ; : SH-DN-ARR E 0 DO DN-ARR LOOP ; : SH-UP-ARR F 0 DO FIND-CR LOOP CHRPTR @ 1+ PAGPTR ! PRTPAG ; : CTL-I FIND-CR INSERT D CHRPTR @ C! RE-PAGE ; : CTL-D CSRAD @ 5E0 AND CSRAD ! FIND-CR CHRPTR @ DUP DUP BEGIN 1+ DUP ENDTXT @ > IF DROP DROP EXIT ENDIF DUP C@ D = UNTIL REPEAT 2DUP - ENDTXT +! SWAP ENDTXT @ CHRPTR @ - CMOVE CHRPTR ! RE-PAGE ; : CTRL-KEY DUP 9 = IF CTL-RT-ARR EXIT ENDIF DUP 8 = IF CTL-LF-ARR EXIT ENDIF DUP 49 = IF CTL-I EXIT ENDIF DUP 44 = IF CTL-D EXIT ENDIF ; : CONTROL TEST-CLEAR IF CTRL-KEY EXIT ENDIF DUP D = IF DN-ARR EXIT ENDIF DUP C = IF EXIT ENDIF DUP 9 = IF RT-ARR CHECK EXIT ENDIF DUP A = IF DN-ARR EXIT ENDIF DUP 8 = IF LF-ARR EXIT ENDIF DUP 5E = IF UP-ARR EXIT ENDIF DUP 5D = IF SH-RT-ARR EXIT ENDIF DUP LOAD commands, thus allowing "sub-files" of subroutines, etc. LOAD commands can be nested in this way up to three files deep (i.e. no more than three open files at one time). The LOAD command reads in the input file and treats it exactly as if it were typed in from the keyboard. Thus direct commands, such as FORGET and FIND are possible as well as colon definitions. You can even have a auto-execute at the end of loadng by putting its name as the last line in your file. Don't try to get any input from the keyboard during a LOAD sequence. For example, if you include in the load file a direct command which executes a word which asks for input, the only input it is going to get is the next word in the LOAD file! If there is no next word (i.e. the commad is the last word in the file) then it is perfectly all right because control reverts back to the keyboard at that point. d which asks for input, the only input it is going to get is the next word in the LOAD file! If there is no next word (i.e. the comm                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                ^kT 05 INTERFACING TO MACHINE LANGUAGE PROGRAMS The EXEC command will effectively jump to the address pointed to by the number on top of the stack. This jump is a JSR instruction, which means that a RTS will return back to Forth. Since there is no CLOADM command in SUPERFORTH, you must load in your machine lanugage program in before SUPERFORTH is loaded. This is no problem as long as you make sure that your program doesn't use an area that is also being used by SUPERFORTH. ^k*ADDENDUM: USING THE EDITOR Using the EDITOR (called EDIT on your tape or disk) may seem a bit confusing if you are accustomed to using a word processor or other editor, as the SUPERFORTH editor has several unconventional aspects: 1) The number of lines in the editor's memory is fixed and can only be changed by 'CLEAR I' and 'CLEAR D'. 2) It is impossible to type past END OF FILE, thus when using the 'NEWFILE' option #1 from the menu, the first asction should be to type a single character ('@' for example) then several 'CLEAR I's to create some space in which to type using the '@' as a marker. 3) The Editor is line-oriented instead of character orientd. In character oriented editors, the entire text is considered as one long sentance, where in line-oriented editors, each line is a discrete unit indipendant of other lines. Character-oriented editors are more appropriate to editing text instead of programs. Remember, this editor is only a sample SUPERFORTH program and that any word processor (like TELEWRITER) that writes ASC files to disk (or tape) will be fine for writing your SUPERFORTH programs. But, the provided editor does the job nicely once you get used to it! Also remember that SUPERFORTH accepts any command directly from the keyboard so you can test the WORDS you build before you compose them later in a program. ur SUPERFORTH programs. But, the provided editor does the job nicely once you get used to it! Also remember that SUPERFORTH accepts any command directly from the keyboard so you                                                                                                                                                                                                                                                                  4 0 Semigraphics 12 6 0 Semigraphics 24 1 128/136 Graphics 1C (color sets0 or 1) 1 144/152 Graphics 1R 2 160/168 Graphics 2C 3 176/184 Graphics 2R 4 192/200 Graphics 3C 5 208/216 Graphics 3R 6 224/232 Graphics 6C 6 240/248 Graphics 6R PTC - Put cursor. Works like PRINT @ to reposition the cursor (and the next printing locatin). Top of stack is the X coordinate (character number) 2nd is Y-coordinate (line number). READ - Reads a character from a disk file. Top of stack must contain the device/buffer number (1,2,3,...etc) and the byte read is left in it's place. RESET - reset a pixel. TOP is X-coordinate, 2ND is Y. Works regardless of graphics mode, but a PMODE command ust previously have been executed for RESET to know what mode it is supposed to use. RND - Generates a random number. The joysticks are used initially as a seed when FORTH first starts up; after that a dual, bi-rotation, exclusive OR shift-register algorithm is used to produce some very random numbers. The number is left on the stack. SCREEN - When executed, this command gets the graphics page to the address contained in the syste variable PAGE, and programs the video mode as set by the last executed PMODE command. By changing PAGE and executing SCREEN each time, it is possible to do "Page-flipping" graphics. SET - Sets a pixel on the screen to the currently specified COLOR. TOP is X-coordinate, 2ND is y. A PMODE command must previously have been executed. SPORT - Opens the sound port. BIP commands will now work. NOTE: reading the joysticks will close the sound port. SQRT - Takes the square root of the number on the top of the stack. The square root algorithm is very fast so don't be afraid to use it. UNTIL - Unlike standard Fig-FORTH, UNTIL does not cause a branch back to BEGIN. UNTIL only EXITS the loop if the condition tested is true; a REPEAT statement is required at the end of every BEGIN loop. This allows the UNTIL (or WHILE) exit to occur anywhere in the loop, not just the beginning or end. VARBL - Pushed the address of the VARIABLE machine code. See CONS. WORD - Unlike standard Fig-FORTH, word does not push the length and address of the string. Instead, WORD gives the string in standard format, i.e. firstcharacter is length byte. CONVENTIONS: Standard Format String: In a standard format string, the number on the stack is an address pointing to the string. The first character of the string is not an ascii character but a one-byte binary number containing the length of the string (not counting the count byte) Double precision numbers: To enter a double precision number, the number must contain a dot (.) USING GRAHICS: Before any graphics commands are executed, the PAGE variable (start of the graphcis page) should be set and a PMODE command executed to insure that the SET, RESET, LINE, PIXEL, and PCLS cmmands are programmed to the proper mode. This is true EVEN IF YOU ARE ONLY GOING TO DO "NORMAL" SEMIGRAPHICS-4. Note also that whenever characters are printed to the screen, it reverts back to alphanumeric mode. The PMODE values are NOT changed by this, however, and subsequent SCREEN commands will put the graphics mode right back. The SET, RESET, PCLS, PIXEL and LINE commands function pretty much identically in all graphics modes. Current PMODE values are checked each time t see if the graphics mode is Semigraphic or Pixelgraphic. The BREAKOUT program contains many different uses of these commands, and has been provided for you to use as an example. USING THE SOUND PORT: FORTH is fast enough where real time synthesis of some basic sounds are possible. For example, a "white noise" generator: SPORT : NOISE 5000 0 DO RND BIP LOOP ; This sends a random number to the port each time the loop is executed. By adding a variable length delay inside the noise loop, variable-frequency effects. Other types of sounds tat have been made are alarms, beeps, variable-frequency oscillators, warbler-sirens, phasers, etc. DISK FILES: If no extension is specified, the extension DAT is default. A zero byte returned indicates end of file on READ. Opening a file for output will automatically create it if it doesn't already exist. Take a close look at the editor program for examples of Disk programming in SUPERFORTH. LOAD COMMAND: The input file of a LOAD command can itself containlor value is taken from the top of the stack, and is as follows: ^k; Semigraphics 4-color 2-color 0=green 0=green/buff 0=black 1=yellow 1=yellow/cyan 3=white/green 2=red 2=red/magenta 1=blue/red 3=blue 3=blue/orange 2=red/blue 4=buff 5=cyan 6=magenta 7=orange ^k; CONS - Leaves the address of the CONSTANT machine-code routine on the stack. The word CONSTANT can be defined as follows: HEX : CONSTANT WORD CREATE 7E C, CONS , , ; This definition gets the next word, compiles a dictionary entry, compiles a JMP (7E) instruction, compiles the address of CONSTANT, and it compiles the number on the top of the stack. When executed, the CONS code will take a number three bytes after the entry point (pointed to by X, normally) and push it onto the stack. COPEN - Open cassette file. The number on top of the stack must point to a string (standard format) which is the name of the file. The second number on the stack must be hex 49 (input) or hex 4F (output). CREAD - Read a byte from the cassette buffer and leave it on the stack. CREATE - Creates a dictionary entry. The top of the stack must have a pointer to the name string (standard form). Any code compiled after tha will be pointed to by that dictionary entry. See CONS for details. CWRITE - Write a byte from the top of the stac to the cassette buffer. EXPECT - Read a line of input from the keyboard, until a carriage return is encountered. No more than 64 characters may be entered. Address of input input string (length byte) is left on stack. DEVNUM - Device number. Pushes the address of the device number on the stack. Used to enable printer output For example: -2 DEVNUM C! Send all output to printer. 0 DEVNUM C! Send all output to screen. FENCE - Stops VLISTing and FORGETing of words after the fence. For example: 67F0 FENCE ! List/Forget only words after 67F0. 6800 FENCE ! List only User defined words. 0 FENCE ! Disable fence. FILES - Reserves n file buffers, where n is top of stack. ICLS - Fills video screen with byte on top of stack. JOY - Read joystick. Reading Joystick 0 refreses all other joystick values, while reading 1-3 only copies previous values. Example: 0 JOY Leave value of joystick 0 on stack 1 JOY joystick 1, etc. K - Same as I and J, except pushes index of 2nd do loop out. See FORTH-79 uncontrolled word definition. KEY* - Same as KEY, except doesn't wait for input. If no key encountered, leaves a zero on stac, otherwise leaves byte. LINE - Draws a line on the screen from (X1,Y1) to (X2,Y2) where X1 is Top of stack, Y1 is second, etc. The line is drawn in the current COLOR (see COLOR command). A PMODE command must previously have been executed. LOAD - Reads and executes an ascii disk fill. The filename must immediately follow the LOAD command. If no extension is specified, DAT is the default. OPEN - Open disk file. Stack must be as follows: TOP points to name string (standard form) 2nd is device/buffer number (1,2,3,...) 3rd is hex 49 (input) or hex 4F (output) 4th if hex 1FF (ascii) or hex 0FF (binary) PAGE - variable containing the address of the next graphics page. Executing SCREEN will program the graphics page to the address pointed to by the contents of PAGE (Example: 1000 PAGE ! SCREEN). SET, RESET, PIXEL, LINE and PCLS all use PAGE as th starting point of the graphics page. "Page Flipping" can be achieved by setting PAGE, drawing the picture, and executing SCREEN. PCLS - Clears the graphics page to the current COLOR (if in 4- or 2-color modes) or black (if in semigraphic). A PMODE command must previously have been executed in order that the PCLS command will know how and where to clear the graphics memory. PIXEL - Test pixel. X coordinate to be tested is top of stack, Y is second. Leaves True or False result depending upon whether pixel is on or off. PMODE - Sets graphics mode reisters. Graphics mode is not altered until SCREEN is executed; however, all subsequent graphics commands will operate in the specified PMODE, whether SCREEN is called or not. The top of stack is written to the VDG chip and the 2nd determines the SAM programming. Here are values for the various graphics modes: 2ND TOP MODE 0 0 Normal/semigraphics4 2 0 Semigraphics 8 ^kT 05 15 25 35 45 55 65 75 ^k*SUPERFORTH MANUAL RUNNING THE PROGRAM Disk: LOADM"FORTH":EXEC Cassette: CLOADM"FORTH":EXEC or CLOADM:EXEC Once started, FORTH will display the prompt ">". This prompt is used whenever FORTH expects user input PROGRAMMING This instruction booklet will by no means attempt to instruct the user in how to program in FORTH. If you are unfamilier with the language, we recommend the book FORTH PROGRAMMING, by Leo J. Scanlon, publish by Howard W. Sams & Co., inc. The definitions of all FORTH words in this program were taken from this book. Also highly recommended is the August 1980 issue of BYTE magazine, which you can probably obtain from your local library. This issue focuses ont the FORTH language and would be of great assistance to those inexperienced with the language. However, though this manual can not feasably ba a FORTH instruction book, there are certain commands peculiar to SUPERFORTH which will require more explanation. These commands have been designed with the particular characteristics of the Color Computer in mind, such as graphics and disk operations, and cannot be covered in a general text. The following is a list of all commands which behave exactly as described in the Fig-FORTH standard: ^k; ! .R = CONSTANT ELSE J PICK U.R # / > COUNT EMIT KEY REPEAT U/ #> /MOD ? CR ENDIF LEAVE ROLL UD. #S 0= @ D+ ERASE LOOP ROT VARIABLE ' 1+ ABS D+- EXECUTE LOOP+ S->D VLIST ( 1- ALLOT D. EXIT M* SO WHILE * 2+ AND D.R FILL M/ SIGN XOR */ 2- BASE DABS FIND MAX SP@ ] */MOD 2DUP BEGIN DECIMAL FORGET MIN SPACE . + : BLANKS DEPTH H MINUS SPACES ." +! ; C! DMINUS HERE MOD STATE +- < C, DO HEX MOVE SWAP , <# C@ DOES> HOLD NOT TYPE - . 2* - Takes the top number on the stac and shifts it left 1 bit 2/ - Takes the top number and shifts right 1 bit BASIC - Returns to basic. Typing EXEC will return to FORTH but all word definitions will be lost. EXEC &H6C4C will return to FORTH without the word definitions being lost. BIP - Takes the number of the top of the stack and writes it to the sound port. The SPORT command must previously have been executed. CCLOSE - Close cassette file CLEAR - Initialize stack to $4FF0 (or SO). CLOAD - Load and execute a source file from cassette. The name of the file must immediately follow. CLOSE - Close a disk file. The number of the fle is taken from the top of the stack. CLS - Clear the text screen. COLOR - Set current color. SET, LINE, and PCLS use this value to determine the drawing color. The coїh:qz+lСD+lШ-l─*vM*vU*v▒/w╝MODw┼/MODw╧M/xU/xM/MODw∙*/xE*/MODx7SQRTv┼EXECUTErLCLEARmДS0n SP@nANDmIORmRXORm[2*mv2/m}1+lu1-l|MINUSlйDMINUSvs+-l▒D+-l╢S->Dv═COMl╜ABSmdDABSmo@l╤C@l╦!l▌+!lфC!l╓?v╒DROPl°SWAPl√ROTmPICKm ROLLmDEPTHm+DUPm;2DUPm@-DUPm7OVERmD=mЩ>m╡wАHOLDwУSIGNwКEMITr&DEVNUMmфCRrDSPACErHSPACESnCOUNTrTYPErKEYr/KEY*r;BASEv DECIMALu№HEXvIp^JpYKpTBASICx╚WORDpi'lэ#INpz*Qx│VLISTx╬LOADzЧFILESz"OPENz+CLOSEz@WRITEzHREADzSVERIFYzaCLOAD{COPEN{ CCLOSE{CWRITE{=CREAD{"CREATErPFINDq4FORGETqJFENCExъEXPECTtg,s▄C,s╩STATEmёHnHEREnALLOTs╡CONSm╫VARBLmщCONSTANTsУVARIABLEsдLEAVEp ERASEtUBLANKStXFILLt\CMOVEtrє]qsPMODE{rPAGE|cSCREEN|2COLOR{╢SET{ЎRESET|PIXEL|LINE|ъPCLS}{PTC}ЧICLS}зCLS}╕SPORT}╝BIP}┼(tgIFsENDIFsELSEsBEGINs4UNTILs<WHILEsMDOs`REPEATs~LOOP+snLOOPss*SrШ."r╕EXITr═;r╟(tg5┐x╠╬GЁнЯа №Z¤n▒№\¤n│╠л═¤n╡╠P¤m∙╠h¤nu&╬OЁОpЩ16 о 0 оф0пфоДнД Ї5~ldо─0п─9о─0п─9о─0п─9о─0п─97у─э─9ьBуFэFьDщAй─эD3D9╠г─э─9ь┴+Ї9ь┴+ ╖9ь─CSэ─9ьBг┴э─9Oц╘э─9о╘п─977чД977эД977уДэД9оb0пbоД6979769707669ь─Xь┼э─97Zўm*X0┼оДьГэzm*&ўп─9я^╠OЁг^GV69о─'о─69ьB6ьB697д─фAэ─97к─ъAэ─97и─шAэ─9ь─*O_г─э─9ь─+■9ь─XIэ─9ь─DVэ─9╬Oю97м─*п─97м─+∙ ї7╠м─&╠  э─9╠о─&╠  э─97╠м─,╠  э─97╠м─/Ї яцAЙэ─9~mьо69~m┌~m┌o~mь069~mь~mьP~mьk╛~mьh№n69╠mЕ69я├97╜rH0&∙9╛pьу┴эг/0┐p ╛pь├эг.ъоbопb97Г'ёоb0пb97Г&т юоb06цД:0пb9╜ny69╢n▒I╕n▒Iyn╢yn╡yn┤yn│yn▓yn▒╢n╣F╕n╣Fvn╖vn╕vn╣№n╖╕n╡°n╢¤n╖9    ╢nїЎn√=¤n°╢nїЎn·=√n°Й¤nў╢nЇЎn√=єnў¤nўIД╖nЎ╢nЇЎn·=єnЎ¤nЎ9  О№oh│ol% │ol¤oh ■yokyoj0'yoiyoh ┘9¤ol┐op┐orО┐onО!№on│ol% │ol¤on ■yosyoryoqyop0'yooyon ╙9¤o▒ОOo│xo│|o│xo▓yo▒Ixo▓yo▒I░o│$ ╗o│zo│0&▌ |o│0&╘Ўo│OTI9╠¤p¤p9╢vЎp=√p Й¤n°╢vЎp=√n°Й¤nў╢vЎp=√nўЙ¤nЎ╢vЎp=√nЎўnЎ№nЎ¤p№n°¤p9  ╛pьэ9p                                ╠ Ў ╠ · ╠ ■╛pьЛ69~l`xrnZpvtgnDpjlp~l`xrnKpНuВnZpvl°nDp{ne?rtsnDp{p╒tgxrnKpЩnl╤p■nKp│rLnDpЭuВnZpЭne NOT DEFINED: umrrnDpЩГOЄ+ ╬OЁ╜umОpё3Оpэ- OK STACK EMPTY╜q ь─'о╪пB9ж╘'╜qшь┴&о─цА:0п─ ъОп─97цА:п─О  69~l`pinl╤p■qClp7&э─9~l`pinl╤qWlp╜q ь┴'о┴╝xъ$ ьД¤m∙0┐n979~l`nDqЗ~l`pirPs╞lэl`s▄m▀mёl▌pim√l╤p■nKqЯrLnDq╪nl╤p■nKqпs▄nDq╪uВnKq┴lэlэs▄s▄nDq╪rne IS UNDEFINED.umsєmёl╤nZqфnDqНlpо─оBцАса&жАба& Z&ў╠  69╠69о─цАOп─4977 7цАжАнЯаZ&ў97ШнЯа9нЯа'·ШO69нЯа&Ї_ ёЖ тЖ ▐7nД╛m∙╛n1>пдц╘O6├6№nг─э─│m∙+¤n7061!6 ~tОrИ6~tDICTIONARY FULL7╠ne╜s▐о─цД\O╛m∙╜s╖цДO\6 6~t~l`x│rШlэrs▄lpО  ┐mЇ╠lp~s▐~l`pirPs╞rрlp╠lX╜s▐№m∙¤rё▄~s▐оb1"пЯrё~lp╠nK╜s▐╛m∙6╠~s▐╛m∙0п╤9╠nD╜s▐╛m∙╠╜s▐╛m∙0п╘п─9╛m∙069╠nZ╜s▐№m∙6╠С╠nK э7&╛pпБэБ┐p9╠sR╜s▐╛m∙069╠n ╠n5╜s▐7`╠nD╜s▐7 7╜s▐╛m∙0пд9~l`pirPs╞m╫s▄s▄lp~l`pirPs╞mщs▄s▄lp7єm∙│n*1¤m∙9Ж~ 7╛m∙0╝n*┐m∙з97╛m∙0╝n*┐m∙э9ОrИ6╛nцД:0┐nь¤m∙О  ┐mЇoЯx▒■707 tSж└за0&°■tS976 tS0Л1лжвз┬0&°■tS9707 tSь┴эб0&°■tS9_ ╞ 770ча0&·9Ж нЯаЖ>нЯа_tйОtк╜tыБ 'нЯаБ' ┴@*эзА\ чМtк'т0 ▐oДўtиЖ нЯа9                                  }u&+8&RжЯИ╖u$ЖА╖u"нЯа' 4╢u$зЯИ5Вzu#&ъ╢u"И╖u"зЯИ ▄ ўu'╜{"77Ўu'M'9u&╜{Ўu' зўu'Ўu&╜yC&Ўu'M'9Ўu&╜y)zu&Ўu' З╜y╒╜umЎ▀Ўu&'у+╜y)zu& ёu&Хо─цаОўv╜o┤vvждБ-&1!zvsvжаБ.'MА0+FБ +АБ +<▒v*7╖p ╜o╛zv&▄}v'╠│n°¤n°╠Єnў▓nЎ¤nЎО  №n°э─}v'№nЎ669|v ╟╠ ¤v 9╠¤v 9~mь ╜v'№n°g╜v'ОnЎjv░╜vX¤nЇ╜vX¤n·n°n∙°{v░╜vX¤ol╜vX¤ojohoi╜n№9ь┴*CS├sv░9ь─*Нsv░77 9╠гBэB╠тAв─э─9}v░'CS├69}v░'╠г"6╠т!вд69ь"6ьд697¤nЇ7¤n·╜n║ОnЎ т7╜ot69ц─Й69ь╘э─ 6╠6 T╜m;╜md╠6 ╠6 ╜l√╜mD╜mo╜wB╜w\╜wК╜wб╜wА√╜m;╜md╠6╜wB╜w\╜wК╜wА·ч╜l√╜mD╜mo ц╜wB╜w\╜wА·╨vО~ ┐w║╛v ┐ol7¤op7¤or9╜wj№op&°№or&є9О┐on╜o7№on╦0┴:+╦ ╞ Н№v69ь┴*╞- 97╛w║чВ┐w║|v9Ўw╣Ёv#╛w║Ж зВ┐w║|v щ9╜v?№oj■┐Н╜v?№oh Н╜v?№oh╜wь№oj■дwыьB*swы9}wы'CS├69╜x№op69777 ╜o'№on6№or69Н╚v░╜vX¤{p╜ve№{p╜o'№on╜wьОop■Z╜wрН №oh╜wьЇ╢v░╜vX¤ol╜vX¤nЇ╜vX¤n·╜n║№nЎ¤oh№n°¤oj╜n№№oj■Ўtй&Оtк ╛x▒жА'(Б '°Оtк_за\жА'Б &їўtй┐x▒ОtйО  6090 ьО69╛x▒Оtк_жА'шБ"'╘за\ єnЯx╠╛nцА'}xэ'╝xэ. ╜r╜rH0 ш9~mьХ4╜╩щ5ў [╬ (О ЙoДп┴0ЙZ"їдt┐ W4K5╜─НР`╫o╜╦oГS╫o╜вВovF╫o╜бv p'Oзфob2╜╞їV&ў ЗM╞ \жЕБ $∙oт╢ ZЧы╬ LЖ з└Г W&°~╔R4zOЛ╢О■ПзН TяН QЖ~3Н╖О ПжфяН @n°T\ _ жН /юН ,╖О ПюН #5z2b]9XОy╨0ЕжАнЯажДнЯаОz╞жАнЯаZ&ў9AODNI                                                                                                                                                                                                                                                                                  ╔ ┼╞─╚!"┼$%┼'()*+,╚├╞012─                 RUN-ME BAS▒NEWFORTHBIN  FORTH BIN# FRTHDOC1TXT |FRTHDOC2TXT &_FRTHDOC3TXT IEDIT DAT ╥PR-DICT DAT -RTXT-DUMPBAS∙FTHFIX TXT .SFORTHTUTBAS/Ш                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                OFMNOIE NE DFOBWPFNFS VF ERROR7ўz*■╩7Н77777 Оz╥╜yН7╜y)Е7ц┴7╜y6 zь─╜yC&√o─зA97■¤zЦОz╥цАжАБ.'Б/'заZ&ё}zЦ&╞ОzТ хoа9|zЦ ч.DAT~l`pizаlp7Н┬}u&&╞ўz*╜xЇЎu&╦ёz*.&ўu&Оz╥О ЖIЎu&╜y&·У9       ╞Оzя╜r╜umё]FILE LEVEL TOO DEEP╞IН╞ ўu&97Ж 4@╜ж5└Ж Чo4@╜д05└╞ ╫o4@╜бv5@M&L p'O6o┬o977╞ ╫o4@╜вВ5@o9о─М&4@ {pнЯа ■{p5@о─цЙZOэ─9ь┴ў{▓&{╡ь┴ў{│Ж]&Ж╖{┤ ь┴ў{│Ж ╖{╡Ў{│XО{дьЕ¤|h9 цAЖU=ў{╠7─Ж=╦Аў{╦9╢{┤цA3BT%H╛|f:цA3B}{│&T%HH╖{їЖ =0ЛжД9}{╡&┘╜{═Й─Ёё{╦'╢{╦║{їзД9╜{═s{ї┤{їзД9╜{═┤{ї'╠  69╠69О └╞╢{│F$з зД0Z&Є╢{▓╖ "╢|fО ╥╞зДH$з0Z&Ї9~mь` └0 А@ ┐|j┐|l╢{│Б'?Е'╞╢|m=╛|f0ЛЎ|kTTT:╢|kДО|}цж9╢|m╞ =╛|f0ЛЎ|kTT:╢|kДО|yцж9╞ ├70╜|ЕШCЇ{╠дДЧ ┌ чД970┐|r┐|t70┐|n┐|p╝|r+╛|r┐|r┐|n╛|p╛|t┐|t┐|p№|r│|n▌О  №|t│|p▌+ О╠У▌Я ▄╙╛|p406 ╛|n6╜{Ў50╢|o▒|s'М+ь||oМ*█▄0Л╓ 1е ╤╝|t&с9╢{╠Ў{╠}{╡&╠АА╛|f╛|hэБ1>&·9жC╞ =у─3DДК▌И97ОО╜t`╠ ъ╞` э╢ #К╖ #97XXў  9                                                                                         ~                                                           l!                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 їh:qz+lСD+lШ-l─*vM*vU*v▒/w╝MODw┼/MODw╧M/xU/xM/MODw∙*/xE*/MODx7SQRTv┼EXECUTErLCLEARmДS0n SP@nANDmIORmRXORm[2*mv2/m}1+lu1-l|MINUSlйDMINUSvs+-l▒D+-l╢S->Dv═COMl╜ABSmdDABSmo@l╤C@l╦!l▌+!lфC!l╓?v╒DROPl°SWAPl√ROTmPICKm ROLLmDEPTHm+DUPm;2DUPm@-DUPm7OVERmD=mЩ>m╡wАHOLDwУSIGNwКEMITr&DEVNUMmфCRrDSPACErHSPACESnCOUNTrTYPErKEYr/KEY*r;BASEv DECIMALu№HEXvIp^JpYKpTBASICx╚WORDpi'lэ#INpz*Qx│VLISTx╬LOADzЧFILESz"OPENz+CLOSEz@WRITEzHREADzSVERIFYzaCLOAD{COPEN{ CCLOSE{CWRITE{=CREAD{"CREATErPFINDq4FORGETqJFENCExъEXPECTtg,s▄C,s╩STATEmёHnHEREnALLOTs╡CONSm╫VARBLmщCONSTANTsУVARIABLEsдLEAVEp ERASEtUBLANKStXFILLt\CMOVEtrє]qsPMODE{rPAGE|cSCREEN|2COLOR{╢SET{ЎRESET|PIXEL|LINE|ъPCLS}{PTC}ЧICLS}зCLS}╕SPORT}╝BIP}┼(tgIFsENDIFsELSEsBEGINs4UNTILs<WHILEsMDOs`REPEATs~LOOP+snLOOPss*SrШ."r╕EXITr═;r╟(tg5┐x╠╬GЁнЯа №Z¤n▒№\¤n│╠л═¤n╡╠P¤m∙╠h¤nu&╬OЁОpЩ16 о 0 оф0пфоДнД Ї5~ldо─0п─9о─0п─9о─0п─9о─0п─97у─э─9ьBуFэFьDщAй─эD3D9╠г─э─9ь┴+Ї9ь┴+ ╖9ь─CSэ─9ьBг┴э─9Oц╘э─9о╘п─977чД977эД977уДэД9оb0пbоД6979769707669ь─Xь┼э─97Zўm*X0┼оДьГэzm*&ўп─9я^╠OЁг^GV69о─'о─69ьB6ьB697д─фAэ─97к─ъAэ─97и─шAэ─9ь─*O_г─э─9ь─+■9ь─XIэ─9ь─DVэ─9╬Oю97м─*п─97м─+∙ ї7╠м─&╠  э─9╠о─&╠  э─97╠м─,╠  э─97╠м─/Ї яцAЙэ─9~mьо69~m┌~m┌o~mь069~mь~mьP~mьk╛~mьh№n69╠mЕ69я├97╜rH0&∙9╛pьу┴эг/0┐p ╛pь├эг.ъоbопb97Г'ёоb0пb97Г&т юоb06цД:0пb9╜ny69╢n▒I╕n▒Iyn╢yn╡yn┤yn│yn▓yn▒╢n╣F╕n╣Fvn╖vn╕vn╣№n╖╕n╡°n╢¤n╖9    ╢nїЎn√=¤n°╢nїЎn·=√n°Й¤nў╢nЇЎn√=єnў¤nўIД╖nЎ╢nЇЎn·=єnЎ¤nЎ9  О№oh│ol% │ol¤oh ■yokyoj0'yoiyoh ┘9¤ol┐op┐orО┐onО!№on│ol% │ol¤on ■yosyoryoqyop0'yooyon ╙9¤o▒ОOo│xo│|o│xo▓yo▒Ixo▓yo▒I░o│$ ╗o│zo│0&▌ |o│0&╘Ўo│OTI9╠¤p¤p9╢vЎp=√p Й¤n°╢vЎp=√n°Й¤nў╢vЎp=√nўЙ¤nЎ╢vЎp=√nЎўnЎ№nЎ¤p№n°¤p9  ╛pьэ9p                                ╠ Ў ╠ · ╠ ■╛pьЛ69~l`xrnZpvtgnDpjlp~l`xrnKpНuВnZpvl°nDp{ne?rtsnDp{p╒tgxrnKpЩnl╤p■nKp│rLnDpЭuВnZpЭne NOT DEFINED: umrrnDpЩГOЄ+ ╬OЁ╜umОpё3Оpэ- OK STACK EMPTY╜q ь─'о╪пB9ж╘'╜qшь┴&о─цА:0п─ ъОп─97цА:п─О  69~l`pinl╤p■qClp7&э─9~l`pinl╤qWlp╜q ь┴'о┴╝xъ$ ьД¤m∙0┐n979~l`nDqЗ~l`pirPs╞lэl`s▄m▀mёl▌pim√l╤p■nKqЯrLnDq╪nl╤p■nKqпs▄nDq╪uВnKq┴lэlэs▄s▄nDq╪rne IS UNDEFINED.umsєmёl╤nZqфnDqНlpо─оBцАса&жАба& Z&ў╠  69╠69о─цАOп─4977 7цАжАнЯаZ&ў97ШнЯа9нЯа'·ШO69нЯа&Ї_ ёЖ тЖ ▐7nД╛m∙╛n1>пдц╘O6├6№nг─э─│m∙+¤n7061!6 ~tОrИ6~tDICTIONARY FULL7╠ne╜s▐о─цД\O╛m∙╜s╖цДO\6 6~t~l`x│rШlэrs▄lpО  ┐mЇ╠lp~s▐~l`pirPs╞rрlp╠lX╜s▐№m∙¤rё▄~s▐оb1"пЯrё~lp╠nK╜s▐╛m∙6╠~s▐╛m∙0п╤9╠nD╜s▐╛m∙╠╜s▐╛m∙0п╘п─9╛m∙069╠nZ╜s▐№m∙6╠С╠nK э7&╛pпБэБ┐p9╠sR╜s▐╛m∙069╠n ╠n5╜s▐7`╠nD╜s▐7 7╜s▐╛m∙0пд9~l`pirPs╞m╫s▄s▄lp~l`pirPs╞mщs▄s▄lp7єm∙│n*1¤m∙9Ж~ 7╛m∙0╝n*┐m∙з97╛m∙0╝n*┐m∙э9ОrИ6╛nцД:0┐nь¤m∙О  ┐mЇoЯx▒■707 tSж└за0&°■tS976 tS0Л1лжвз┬0&°■tS9707 tSь┴эб0&°■tS9_ ╞ 770ча0&·9Ж нЯаЖ>нЯа_tйОtк╜tыБ 'нЯаБ' ┴@*эзА\ чМtк'т0 ▐oДўtиЖ нЯа9                                  }u&+8&RжЯИ╖u$ЖА╖u"нЯа' 4╢u$зЯИ5Вzu#&ъ╢u"И╖u"зЯИ ▄ ўu'╜{"77Ўu'M'9u&╜{Ўu' зўu'Ўu&╜yC&Ўu'M'9Ўu&╜y)zu&Ўu' З╜y╒╜umЎ▀Ўu&'у+╜y)zu& ёu&Хо─цаОўv╜o┤vvждБ-&1!zvsvжаБ.'MА0+FБ +АБ +<▒v*7╖p ╜o╛zv&▄}v'╠│n°¤n°╠Єnў▓nЎ¤nЎО  №n°э─}v'№nЎ669|v ╟╠ ¤v 9╠¤v 9~mь ╜v'№n°g╜v'ОnЎjv░╜vX¤nЇ╜vX¤n·n°n∙°{v░╜vX¤ol╜vX¤ojohoi╜n№9ь┴*CS├sv░9ь─*Нsv░77 9╠гBэB╠тAв─э─9}v░'CS├69}v░'╠г"6╠т!вд69ь"6ьд697¤nЇ7¤n·╜n║ОnЎ т7╜ot69ц─Й69ь╘э─ 6╠6 T╜m;╜md╠6 ╠6 ╜l√╜mD╜mo╜wB╜w\╜wК╜wб╜wА√╜m;╜md╠6╜wB╜w\╜wК╜wА·ч╜l√╜mD╜mo ц╜wB╜w\╜wА·╨vО~ ┐w║╛v ┐ol7¤op7¤or9╜wj№op&°№or&є9О┐on╜o7№on╦0┴:+╦ ╞ Н№v69ь┴*╞- 97╛w║чВ┐w║|v9Ўw╣Ёv#╛w║Ж зВ┐w║|v щ9╜v?№oj■┐Н╜v?№oh Н╜v?№oh╜wь№oj■дwыьB*swы9}wы'CS├69╜x№op69777 ╜o'№on6№or69Н╚v░╜vX¤{p╜ve№{p╜o'№on╜wьОop■Z╜wрН №oh╜wьЇ╢v░╜vX¤ol╜vX¤nЇ╜vX¤n·╜n║№nЎ¤oh№n°¤oj╜n№№oj■Ўtй&Оtк ╛x▒жА'(Б '°Оtк_за\жА'Б &їўtй┐x▒ОtйО  6090 ьО69╛x▒Оtк_жА'шБ"'╘за\ єnЯx╠╛nцА'}xэ'╝xэ. ╜r╜rH0 ш9~mьХ4╜╩;5ў [╬ (О ЙoДп┴0ЙZ"їдt┐ W4K5╜─hР`╫o╜╩SoГS╫o╜вВovF╫o╜бv p'Oзфob2╜╞┼V&ў ЗM╞ \жЕБ $∙oт╢ ZЧы╬ LЖ з└Г W&°~╚д4zOЛ╢О■ПзН TяН QЖ~3Н╖О ПжфяН @n°T\ _ жН /юН ,╖О ПюН #5z2b]9XОy╨0ЕжАнЯажДнЯаОz╞жАнЯаZ&ў9AODNIOFMNOIE NE DFOBWPFNFS VF ERROR7ўz*■╩7Н77777 Оz╥╜yН7╜y)Е7ц┴7╜y6 zь─╜yC&√o─зA97■¤zЦОz╥цАжАБ.'Б/'заZ&ё}zЦ&╞ОzТ хoа9|zЦ ч.DAT~l`pizаlp7Н┬}u&&╞ўz*╜xЇЎu&╦ёz*.&ўu&Оz╥О ЖIЎu&╜y&·У9       ╞Оzя╜r╜umё]FILE LEVEL TOO DEEP╞IН╞ ўu&97Ж 4@╜ж5└Ж Чo4@╜д05└╞ ╫o4@╜бv5@M&L p'O6o┬o977╞ ╫o4@╜вВ5@o9о─М&4@ {pнЯа ■{p5@о─цЙZOэ─9ь┴ў{▓&{╡ь┴ў{│Ж]&Ж╖{┤ ь┴ў{│Ж ╖{╡Ў{│XО{дьЕ¤|h9 цAЖU=ў{╠7─Ж=╦Аў{╦9╢{┤цA3BT%H╛|f:цA3B}{│&T%HH╖{їЖ =0ЛжД9}{╡&┘╜{═Й─Ёё{╦'╢{╦║{їзД9╜{═s{ї┤{їзД9╜{═┤{ї'╠  69╠69О └╞╢{│F$з зД0Z&Є╢{▓╖ "╢|fО ╥╞зДH$з0Z&Ї9~mь` └0 А@ ┐|j┐|l╢{│Б'?Е'╞╢|m=╛|f0ЛЎ|kTTT:╢|kДО|}цж9╢|m╞ =╛|f0ЛЎ|kTT:╢|kДО|yцж9╞ ├70╜|ЕШCЇ{╠дДЧ ┌ чД970┐|r┐|t70┐|n┐|p╝|r+╛|r┐|r┐|n╛|p╛|t┐|t┐|p№|r│|n▌О  №|t│|p▌+ О╠У▌Я ▄╙╛|p406 ╛|n6╜{Ў50╢|o▒|s'М+ь||oМ*█▄0Л╓ 1е ╤╝|t&с9╢{╠Ў{╠}{╡&╠АА╛|f╛|hэБ1>&·9жC╞ =у─3DДК▌И97ОО╜t`╠ ъ╞` э╢ #К╖ #97XXў  9                                                                                         ~                                                           l!                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 ^kT 05 20 SUMMARY OF FORTH WORDS d.p. = double precision n = number (16 bits) b = byte (8 bits) = 1 character d = double number (32 bits) r = logical result: True(-1) or false(0) un = unsigned number top = top number on stack 2nd = 2nd number on stack 3rd = etc. ARITHMETRIC OPERATORS ^k; + n1 n2 --> n1+n2 addition - n1 n2 --> n1-n2 subtraction * n1 n2 --> n1*n2 multiplication / n1 n2 --> n1/n2 division, quotient result MOD n1 n2 --> n3 division, n3 = remainder result /MOD n1 n2 --> n3 n4 division, n3=remainder, n4=quotient 1+ n1 --> n1+1 increment by 1 1- n1 --> n1-1 decrement by 1 2+ n1 --> n1+2 increment by 2 2- n1 --> n1-2 decrement by 2 2* n1 --> n1*2 shift left 1 bit 2/ n1 --> n1/2 shift right 1 bit MINUS n1 --> -n1 multiply by -1 ABS n1 --> abs(n1) absolute value SQRT n1 --> n2 square root RND --> n1 random number function MIN n1 n2 --> n3 n3 = smaller of the two MAX n1 n2 --> n3 n3 = larger of the two +- n1 n2 --> n3 n3 = n1 * sign(n2) D+ d1 d2 --> d1+d2 double precision addition DMINUS d1 --> -d1 multiply by -1 d.p. DABS d1 --> abs(d1) absolut value d.p. S->D n1 --> d1 sign extend from sigle to double D+- d1 n1 --> d2 d2 = d1 * sign(n1) M* n1 n2 --> d1 multiply w. d.p. result U* un1 un2 --> d1 unsigned multiply w. d.p. result M/ d1 n1 --> n2 n3 digide d.p. number by single single precision divisor, leaving remainder (n2) and quotient (n3) U/ ud1 un1 --> n2 n3 same as M/, but divident and divisor is unsigned M/MOD ud1 un1 --> n2 d2 same as U/, but quotient is d.p. */ n1 n2 n3 --> n4 fraction. n4 = n1*(n2/n3) */MOD n1 n2 n3 --> n4 n5 fraction with remainder n5=n1*(n2/n3), n4=remainder ( DO...LOOP ) DO n1 n2 --> loop from n2 to n1 I --> n1 push index of loop J --> n1 push index of first outside loop K --> n1 push index of second outside loop LEAVE set index of loop to final value LOOP increment index by 1, go back to DO LOOP+ n --> increment index by n, go back to DO GRAPHICS COMMANDS PMODE n1 n2 --> set graphics mode but don't change n1=SAM programming value, n2=VDG programming value PAGE --> n1 address of variable containing the location of the graphics page SCREEN change video mode to current PMODE values, set graphics page to value of page. COLOR n --> set current color to color n SET n1 n2 --> set pixel (n2,n1) to current color RESET n1 n2 --> reset pixel (n2,n1) PIXEL n1 n2 --> text pixel (n2,n1) LINE n1 n2 n3 n4 --> draw line from (n2,n1) to (n4,n3) PCLS clear screen to current color CLS clear text screen ICLS b --> clear text screen with byte b PTC n1 n2 --> put cursor at line n1, character n2 MISCELLANEOUS BASIC return to basic EXECUTE n --> jump to address n (JSR) ' name code address of name ( comment JOY n --> b read joystick n SPORT turn on sound port BIP b --> send byte b to sound port SYSTEM USE COMMANDS CONS --> n push address of CONSTANT machine code VARBL --> n push address of VARIABLE machine code *Q --> n read input from keyboard until quote or CR encountered, n=string address *S n --> compile embedded string, n=string address SO --> n leave address of variable where initial stack address is stored SP@ --> n leave location of top of stack DISK AND CASSETTE I/O LOAD name load and execute ascii file OPEN n1 b2 n3 n4 --> open disk file. n1=$1FF(ascii) or $100(binary), b2=$49(input) or $4F (output), n3=buffer/file number, n4=pointer to name-string CLOSE n --> close file n (n=buffer number) READ n --> b read character from file n WRITE b n --> write character b to file n FILES n --> allocate n file buffers VERIFY n --> n=0, verify off, n<>0 verify on CLOAD name load and execute cassette file COPEN n1 b1 --> open cassette file, n1 points to name-string; b1=$49(input) or $4F (output) CCLOSE close cassette file CREAD --> b read byte from cassette CWRITE b --> write byte to cassette COMPILING WORDS : name start colon compilation ; end colon compilation EXIT early exit from word CONSTANT compile constant n1 CONSTANT name VARIABLE compile variable n1 VARIABLE name create run-time code CREATE n1 --> build a dictionary entry and compile a threaded code header, n1 points to name-string , n --> compile a word of code C, b --> compile a byte of code ALLOT b --> reserve b bytes of compiled code STATE --> n push address of compile flag ] resume colon compilation in build/does construct CONTROL STRUCTURES ( IF...ENDIF and IF...ELSE...ENDIF ) IF n1 --> if n1<>0, perform if clause, if n=0 perform else clause or skip to endif ( BEGIN...REPEAT ) BEGIN begin loop WHILE n --> if n=0, exit loop UNTIL n --> if n<>0, exit loop REPEAT go back to BEGIN LOGICAL OPERATORS AND n1 n2 --> n3 logical and OR n1 n2 --> n3 logical inclusive or XOR n1 n2 --> n3 logical exclusive or COM n1 --> n2 one's complement NOT n1 --> n2 n2=0 if n1<>0, n2=-1 if n1=0 = n1 n2 --> r1 True if n1 = n2 > n1 n2 --> r1 True if n1 > n2 < n1 n2 --> r1 True if n1 < n2 0= n1 --> r1 True if n1 = 0 0< n1 --> r1 True if n1 negative STACK OPERATIONS DUP n1 --> n1 n1 make 2 copies -DUP n1 --> n1 (n1) DUP only if n1<>0 2DUP n1 n2 --> n1 n2 n1 n2 copy both top and 2nd numbers or d1 --> d1 d1 copy 1 d.p. number SWAP n1 n2 --> n2 n1 reverse top and second OVER n1 n2 --> n1 n2 n1 make copy of second ROT n1 n2 n3 --> n2 n3 n1 put 3rd on top PICK n --> n1 replace n with nth # on stack ROLL n --> take nth number from stack, put on top, slide all others down 1 DROP n --> throw away top number DEPTH --> n n = current stack depth CLEAR initialze stack to $4FF0 MEMORY OPERATIONS @ n1 --> (n1) get number at address n1 C@ n1 --> (b1) get byte at address n1 ! n1 n2 --> store n1 at address n2 C! b1 n2 store b1 at address n2 +! n1 n2 --> add to memory:(n2)+n1-->(n2) FILL n1 n2 b1 --> fill memory with b1, starting at n1 for n2 bytes ERASE n1 n2 --> fill memory with zeroes, starting at n1 for n2 bytes BLANKS n1 n2 --> fill memory with blanks, starting at n1 for n2 bytes MOVE n1 n2 n3 --> move n3 numbers from n1 to n2 (from low to high) CMOVE n1 n2 n3 --> move n3 bytes from n1 to n3 (low-hi) same as CMOVE on from high to low TERMINAL I/O OPERATIO]NS KEY --> b1 input character from keyboard KEY* --> b1 input byte from keyboard, 0 if none EMIT b1 --> print character to video SPACE print 1 space SPACES n --> print n spaces CR print a charriage return COUNT n1 --> n2 b1 converts standard string form to TYPE form TYPE n b --> Types b characters starting from address n DEVNUM --> n address of device number ($6F) EXPECT --> n read one line of input from keyboard n is pointer to string WORD --> n read one word from keyboard n points to string #IN --> n1 input a number from keyboard ." string type a string (compile mode only) NUMERIC OUTPUT AND NUMBER CONVERSION . n1 --> prints a number on keyboard U. un1 --> prints unsigned number .R n1 b1 --> prints n1 right justified U.R un1 b1 --> unsigned right justified in field field length b1 D. d1 --> print double precision number UD. ud1 --> double precision unsigned D.R d1 b1 --> d.p. right justify ? n1 --> print at address n1 BASE --> n1 push address of conversion base DECIMAL change to BASE 10 HEX change to BASE 16 <# start special conversion # convert 1 digit #S convert remaining digits #> end special conversion SIGN insert sign if top negative HOLD insert alpha character in special conversion DICTIONARY OPERATIONS HERE --> n1 push address of dictionary start H --> n1 push address of HERE FIND name --> n1 find code address of word, 0 if not found VLIST type list of words defined FORGET name remove from dictionary word that follows FORGET and all succedding words FENCE --> n1 address of fence. Inhibits FORGET and VLIST MEMORY MAP $0000-$03FF System use $0400-$0600 Text Screen $0600-$3FFF Main memory area: File control block at $0BA2, each block 281 (199 hex) bytes long Graphics pages: Allocated by user. Except for file control blocks, this area is not used by SUPERFORTH (it is used by EDIT) $4000-$4100 Data/parameter stack $4100-$4200 Program control stack $4200-$6800 Forth dictionary area: The dictionary of executable code starts at $4200 and grows upwards, The dictionary of names starts at $6800 and grows downward. $6800-$7FFF SUPERFORTH program $8000+ System ROM EDITOR Included with the SUPERFORTH disk/cassette is a file called "EDIT.DAT". To load this file on a disk system, first enter Superforth and type "LOAD EDIT" (The .DAT extension is default) For cassette users, the EDIT program is on the tape immediately after SUPERFORTH. Once SUPERFORTH is loaded, you can stop the cassette, type "CLOAD" and restart the tape. You might want to copy the editor to a different tape for more convenience. This is easily done, since the editor can load itself. Upon completion of loading, the program will display a menu of options asking the user what type of input file he wishes to edit. Once the appropriate option number (1,2 or 3) is selected the program will then ask for a filename (unless the user selected the NEW FILE option). Once the ile is loaded, the screen will display the first page of the file. From this point you can begin editing or creating text. From this point, you can perform the following commands: Typing normally will cause the letters typed to be written over the data allready there. It works just like a normal typewriter. Do not type past the end of a line, or else the screen display may look funny (It doesn't know how to handle lines longer than 32 characters). Special control keys are provided for editing functions: up arrow-move cursor up one line down arrow-move cursor down one line right arrow-move cursor right one character left arrow-move cursor left one character shift up arrow-move cursor up one page shift down arrow-move cursor down one page shift right arrow-move cursor to end of line shift left arrow-move cursor to begginning of line CLEAR key-used as special function key (works like shift) clear right arrow-insert one blank character clear left arrow-delete on character clear D-delete a line clear I-insert a line shift @-shift lock break-go to main menu The BREAK key causes the program to go to the main menu, which asks you what you want to do next (save the file, read in another file, return to FORTH, etc) Once you have left the editor, you may re-enter without reloading by typing EDIT. If you do not wish to re-enter the editor, you may free up the memory used by typing "FORGET BUFFER". BUFFER is the first word defined in EDIT, thus FORGET BUFFER will delete all words defined after that. The editor is written entirely in Forth, so that you can customize it to your own needs. (you can even use the editor to edit itself!). If you decide to do this, however, make sure you have a copy of the original editor saved somewhere, as it is easy to make a mistake. Do not attempt to do this unless you are fairly confident of your mastery of Forth, because the edito is a fairly complex program. Customizing the editor will allow you to add FIND/SEARCH type commands, as well as a printer option (although files creaded by the editor can easily be printed using a BASIC program). The editor is a bare-bones program, not designed to replace a commercial word proccessor. In particular, it has difficulty handling lines longer than 32 characters. For this reason, it is recomended that you limit all input lines to less that this amount. If you feel the edior is too limited for you, you can also used a word processor to edit your forth program. SUPERFORTH will accept any standard ASCII file as input. BREAKOUT GAME Also included with SUPERFORTH is a pong-type breakout game. Like the editor, it is written in Forth and can be modified by you using the editor (save a copy firth, though) To run BREAKOUT, enter Forth and "LOAD BREAKOUT" (for cassette use the CLOAD command). The game will auto execute, so have a joystick in hand as you do this. The object of the game is to break down the entire wall before 10 balls are expended. Once the game is done, you may re-run it by typing "BREAKOUT" which is the name of the main routine of the game. auto execute, so have a joystick in hand as you do this. The object of the game is to break down the entire wall before 10 balls are expended. Once the game is d                                                                                                                                                                                                                                                                HEX 0 VARIABLE DPOS 0 VARIABLE WDNO 6800 CONSTANT D-BGN : INC-DPOS ( --DADR ) DPOS @ 1+ DUP DPOS ! D-BGN + ; : PR-WDNO ( --WDLN ) DPOS @ D-BGN + C@ DUP 0= IF EXIT ENDIF WDNO @ 1+ DUP WDNO ! DECIMAL 5 .R HEX ; : TYP-WD ( -- ) INC-DPOS DUP 1- C@ DUP DPOS +! A OVER - ROT ROT 2 SPACES TYPE SPACES ; : PR-WADR ( -- ) INC-DPOS 1- @ U. CR 1 DPOS +! ; : PR-DICT ( -- ) ." READY PRINTER " KEY 3 = IF EXIT ENDIF -2 DEVNUM C! ." WD# WORD ADR " CR BEGIN PR-WDNO WHILE TYP-WD PR-WADR REPEAT 0 DEVNUM C! ; PR-DICT  @PR-WADR ( -- ) INC-DPOS 1- @ U. CR 1 DPOS +! ; : PR-DICT ( -- ) ." READY PRINTER " KEY 3 = IF EXIT ENDIF -2 DEVNUM C! ." WD# WORD ADR " CR BEG                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 FIXES FOR FORTH DISK AS RECIEVED FROM PUBLIC DOMAIN SOFTWARE After recieving the forth disk from Public Domain Software I encountered a few problems. I am now sending a new disk with these problems solved. The following is a list of the revisions that were made. 1. The edit file contained a null ($0) at the beginning and so would not load. This was corrected and reloaded onto disk. The remaining changes were added to the edit program and so are in effect only after edit has been loaded. 2. A REDIT command was added to reenter the editor without clearing the text buffer. 3. LLIST lists the text buffer to printer. 4. L lists the current page of the text buffer on the screen while you are still in Forth. 5. .S is simply an emit without affecting the stack. I hope these changes make your journey into FORTH more enjoyable. If you have any questions or further interest in Forth please feel free to drop me a line. I am currently working on a new version from scratch which will utilize the COCO 3's full memory and other potentials. It will also compile code into a stand alone machine code program. Any suggestions or help will be appreciated. Michael Talcott (MIKETALCOTT - on COCO SIG) Rte 1 Box 149 Hardensburg, IN 47125 (currently at 5511 Dayton Blvd. Lot 8 Chattanooga, Tn 37415 until Spring 88) machine code program. Any suggestions or help will be appreciated. Michael Talcott (MIKETALCOTT - on COCO SIG) Rte 1 Box 149 Hardensburg, IN 47125 (currently at 55                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 Х&9:Г INTERNATIONAL COLOR COMPUTER CLUB INC LIBRARY&P:Г 119 COUNTY FAIR&m:Г HOUSTON, TEXAS 77060&| :Гtutorial'eЖ .,+,-,*,/,DUP,SWAP,OVER,ROT,DROP,.S,VLIST,CLS,STACK,SOURCE,BYE,-DUP,VARIABLE,@,!,+!,CONSTANT,CR,?,SPACES,>R,R>,MOD,/MOD,EMIT,STD,FORGET,EMPTY,*/,*/MOD,=,>,AND,OR,KEY,2DROP,2DUP,2SWAP,2OVER,2ROT,R,*/MOD,MIN,MAX,ABS,MINUS,XOR,0<'АЖ 0=,?TERMINAL,I,<,END'КБе825'а:Гstack underflow'╦#ЕP│м1 з З" STACK EMPTY";:а100,5:Бе850'╤(Р'■-Е P┤1 з З " STACK EMPTY"; :а100,5 :Бе850(2Р( 7:Г/0(<<Е S(P)│0 з З" /0 ERROR";:а100,5:P│м1:Бе850(BAР(eF:Гnext word finder: Z RETURNED(║KАJ│Z е I:C$│ Р(I$,J,1):Е C$│Q$ з Л J:Бе80 :Д Z│ Ю(J,I$,Q$):W$│ Р(I$,J,ZмJ):N│Z:Р)PЕ Q$│" " з З" WE'RE SHORT A WORD!"; :Д З" WE NEED A < "лQ$л" >!";)Uа100,5:Бе850)+Z:Гdictionary overflow)g_ЕE│H зЗ"USER DICTIONARY FULL!";:а100,5:E│Eм1:Бе855 :Д Р)yd:Гdefinitions)Гi:Гw.w)мnБж35:Е S(P)▓м1 зЗS(P); :Д З" ";S(P);)╕sP│Pм1:Р)┬x:Гw+w)ц}Бж45 : S(Pм1)│S(P)лS(Pм1):P│Pм1)ьВР)ЇЗwмw*МБж45 : S(Pм1)│S(Pм1)мS(P):P│Pм1*СР*(Ц:Гw*w*LЫБж45:S(Pм1)│S(P)нS(Pм1):P│Pм1:Р*Vа:Гw/w*ГеБж60:Бж45:S(Pм1)│ Ш(S(Pм1)оS(P)):P│Pм1:Р*Нк:Гdup*кпБж35:S(Pл1)│S(P):P│Pл1:Р*╡┤:Гswap*ц╣Бж45:S(Pл1)│S(P):S(P)│S(Pм1):S(Pм1)│S(Pл1):Р*ё╛:Гover+├Бж45:S(Pл1)│S(Pм1):P│Pл1:Р+╚:Гrot+e═P│Pм1:Бж45:P│Pл1:S(Pл1)│S(Pм2):S(Pм2)│S(Pм1):S(Pм1)│S(P):S(P)│S(Pл1):Р+p╥:Гdrop+Б╫Бж35:P│Pм1:Р+К▄:Г.s+╬сЕ P│м1 з З" STACK EMPTY";:Р :Д З" ";:А S│P е 0 йм1:ЗS(S);:Л S:Р+┌ц:Гvlist+їыЮ:П:З:З"SYSTEM WORDS:",!ЁН D$:Е D$│"END"з 245 :Д З D$л" ";:Бе240,IїЗ:З б(32,"-");"USER DEFINED WORDS:",o·АM│0еE:Е N$(M)┤▓""з ЗM;N$(M);" ";,З ЛM:З:З б(32,"-");:Р,ЦЮ:Р :Г cls,в :ГSTACK,╟Бж35:З:АS│P е 0 йм1:З S(S):Л S:Р,╘:Гsource,фQ$│" ":Бж75-АM│1еE:Е N$(M)│W$ зЗM;"'TH USER DEFINITION= ";:Бе 320-+"ЛM:П:O│0-:'Н D$:O│Oл1-J,ЕD$│W$з315 -А1ЕD$│"END"зЗ" THIS WORD IS NOT DEFINED!";:а100,5:Р-К6Бе295-╛;ЗO;"'TH WORD. DEFINITION BEGINS AT";Oн10л100;:Р-ё@ЕB$(M)│"&"зЗV(M):Р :Д З": "лN$(M)лB$(M)л" ;":Р.<EЗ:З" SO LONG! YOU'RE BACK IN BASIC!":З" MAY THE FORTH BE WITH YOU!":К.GJ:Г-dup.kOЕ S(P)┤▓0 з P│Pл1:S(P)│S(Pм1):Р.zT:Гvariable.ПYБж35:Q$│" ":Бж75.├^E│Eл1:Бж95:N$(E)│W$:B$(E)│"&":V(E)│S(P):P│Pм1:Р.═c:Гw@w.хhБж35:S(P)│V(S(P)):Р.яm:Гw!w/rБж45:V(S(P))│S(Pм1):P│Pм2:Р/w:Гw+!w/B|Бж45:V(S(P))│V(S(P))лS(Pм1):P│Pм2:Р/QБ:Гconstant/fЖБж35:Q$│" ":Бж75/ХЛE│Eл1:Бж95:N$(E)│W$:B$(E)│ И(S(P)):P│Pм1:Р/ЮР:Гcr/жХЗ:Р/░Ъ:Гw?w/╦ЯБж35:ЗV(S(P));:P│Pм1:Р/╪д:Гspaces/ьйАJ│1еS(P):З" ";/√оЛJ:P│Pм1:Р0│:Г>r0%╕Бж35:G│Gл1:R(G)│S(P):P│Pм1:Р0.╜:Гr>0Б┬ЕG│м1з З" RETURN STACK EMPTY!";:а 100,5:G│м1:P│м1:Р :Д P│Pл1:S(P)│R(G):G│Gм1:Р0Л╟:Гmod0═╠Бж45:QQ│ Ш(S(Pм1)оS(P)):MOD│S(Pм1)мQQнS(P):S(Pм1)│MOD:P│Pм1:Р0╪╤:Г/mod0Є╓Бж460:P│Pл1:S(P)│QQ:Р0¤█:Гemit1рБж35:З Л(S(P));:P│Pм1:Р1#х:Гstd1`ъЕ P│м1з З" (--)";:Р :Д З" (";:АM│0еP:ЗS(M);:Л:З"-- )";:Р1mя:Гforget1}ЇQ$│" ":Бж751╝∙АM│1е E:Е N$(M)│W$з А J│M е E:N$(J)│"":B$(J)│"":ЛJ:E│Mм1:Р1щ■ЛM:З " "лW$л" IS NOT DEFINED!";:а100,5:Р1ї:Гempty2Ю:О10202  :Гw*/w2;Бж60:S(Pм2)│ Ш(S(Pм2)нS(Pм1)оS(P)):P│Pм2:Р2H:Гw*/mod2ЭБж60:AA│S(Pм2)нS(Pм1):BB│AAоS(P):S(Pм1)│ Ш(BB):S(Pм2)│ Б(AAмS(Pм1)нS(P)):P│Pм1:Р2з!:Гw=w2╨&Е S(P)│S(Pм1)з S(Pм1)│1 :Д S(Pм1)│ 02▄+P│Pм1:Р2ц0:Гw>w35Бж45:Е S(Pм1)▓S(P)з S(Pм1)│1 :Д S(Pм1)│03:P│Pм1:Р3)?:Гand3YDЕS(P)┤▓0 ░ S(Pм1)┤▓0 з S(Pм1)│1 :Д S(Pм1)│03eIP│Pм1:Р3nN:Гor3ЮSЕ S(P)┤▓0 ▒ S(Pм1)┤▓0 зS(Pм1)│1 :Д S(Pм1)│03кXP│Pм1:Р3┤]:Гkey3└bKEY$│""3єgKEY$│ Т:Е KEY$│""з615 :Д P│Pл1:S(P)│ К(KEY$):Р3 l:Г2drop4qБж45:P│Pм2:Р4v:Г2dup4F{Бж45:P│Pл2:S(P)│S(Pм2):S(Pм1)│S(Pм3):Р4RА:Г2swap4░ЕЕP┤3 з P│м1:Бе35 :Д P│Pл2:S(P)│S(Pм4):S(Pм1)│S(Pм5):А J│Pм5 е Pм2:S(J)│S(Jл2):Л J:P│Pм2:Р4╝К:Г2over4╤ПP│Pм3:Бж35:P│Pл54ёФS(P)│S(Pм4):S(Pм1)│S(Pм5):Р4№Щ:Г2rot5 ЮP│Pм6:Е P┤м1зP│м1:Бе35 :Д P│Pл85>гS(P)│S(Pм6):S(Pм1)│S(Pм7)5gиА J│Pм5 е P :S(Jм2)│S(J):Л J:P│Pм2:Р5oн:Гr5Е▓P│Pл1:S(P)│R(G):Р5С╖:Г*/mod5Ы╝Бе4705е┴:Гmin5╩╞Бж45:ЕS(P)┤S(Pм1) з S(Pм1)│S(P) 5╓╦P│Pм1:Р5р╨:Гmax6╒Бж45:Е S(P)▓S(Pм1)зS(Pм1)│S(P)6┌P│Pм1:Р6▀:Гabs62фБж35:S(P)│ В(S(P)):Р6>щ:Гminus6TюБж35:S(P)│мS(P):Р6^є:Гxor6Н°Бж45:Е S(P)лS(Pм1)│1 зS(Pм1)│1 :Д S(Pм1)│06Щ¤P│Pм1:Р6в:Г0<6╞Е S(P)┤0 з S(P)│1:Р :Д S(P)│0:Р6╤ :Гw0=w6їЕ S(P)│0 з S(P)│1:Р :Д S(P)│0:Р7:Г?terminal:DEFINED AS INKEY$7KKEY$│ Т: Е KEY$│"" з Р :Д P│Pл1:S(P)│ К(KEY$):Р7S :Гi7i%P│Pл1:S(P)│R(G):Р7s*:ГwБж1170::Гlogo7ыC:Гinterpreter8HХ 1000:МS(50),R(10),V(20):МB$(20),N$(20):Ю8.ME│0:H│20:Q$│" "8@RN│1:P│м1:G│м18QWN│1: З " OK"8i\A│ Ж(136):B│ Ж(137)8ta╗Й I$ 8БfI│ З(I$)8аkI│ З(I$):Т 136,A:Т 137,BлI8┤pI$│I$л" ":I│Iл18╠u:Гread input stream8№zА J│N е I:C$│ Р(I$,J,1):ЕC$│" "з Л J :Бе8559:Гan item met95ДZ│ Ю(J,I$," "):W$│ Р(I$,J,ZмJ):N│Z9TЙ:Гj=start ; z-1=end WRT I$9vОБж930::Гtest and execute item9ЗУЕ N▓Iм2 з8559ЯШБе890 ::Гmore in i$9┤Э:Гword or number9свX$│" "лW$:X│ Й(W$):Е X┤0з P│Pл1:S(P)│X:Р:зЕ И(X)│X$з P│Pл1:S(P)│X:Р :Д 960:!м:Гused dfnd word found:V▒Е О(B$(M),1)│"&"зP│Pл1:S(P)│M:Р::Гvariable found:Ф╢I$│B$(M)л П(I$,IмZл1):N│1:I│ З(I$):Бе890::Гuser dfn to i$:ж╗:Гword lookup:▒└АM│1еE:─┼ЕN$(M)│W$з 945:╦╩ЛM:╒╧П:O│0:ф╘Н D$:O│Oл1;"┘Е D$│"END" з З " "лW$л" IS NOT DEFINED!";:а 100,5:П:Бе850;?▐Е D$│W$ з Бе 1000::Д 980;Tу:Гbranch to word":Бж1045:Бж1045:Бж1055=ж:Гinstructions input=╓З@448," FOR INSTRUCTIONS, ELSE forth";:Р=э:Гtitle page input>#KEY$│ Т:Е KEY$│""з1055 :Д Е KEY$│"I" з1075 :Д 830>:$:Гinstr page input>m)KEY$│ Т:Е KEY$│""з1065 :Д Е KEY$│"I"з Р :Д 830>z.:Гpage 1>ж3Ю:З"RATIONALE OF THE STACK":З б(32,"-")?8З"IT'S SIMPLE: IF YOU HAVE THINGS IN THE ORDER YOU USE THEM, THEN WHAT IS NEEDED IS ALWAYS AT HAND.";?E=З" STACK MANIPULATIONS MAINTAIN ORDER-OF-USE."?ёBЗ"AS ALL WORK OCCURS AT STACK TOP,INTERMEDIATE RESULTS ARE TYPICALLY (1)SHIFTED TO RETURN STACK OR (2) HELD ON STACK WITH NEEDED DATA MOVED TO TOP BY SWAP/OVER/ROT."@GБж1045:Бж1065@L:Гpage 2@5QЮ:З:З"SPECIAL HELPS":З б(32,"-")AVЗ"STACK -- DISPLAYS THE STACK AS A STACK.":З"STD -- DISPLAYS THE STACK AS A forth PROGRAM COMMENT.":З".S -- PRINTS STACK AS IF BY DOTS";:З"SOURCE (A WORD) -- LOCATES WORD":З"VLIST -- LISTS DICTIONARY"A[Бж1045:Бж1065A#`:Гpage 3B eЮ:З:З"STD DISPLAYS THE STACK WITH BOTTOM ON LEFT,TOP ON RIGHT. IT IS BY FAR THE BEST WAY TO REPRESENT THE STACK AS THIS IS THE ORDER OF DATA ENTRY.":З"USE VLIST TO EXPLORE AND TO KEEPTRACK OF CONSTANTS AND VARIABLES YOU DEFINE."BgjЗ:З"REMEMBER: any undefined word clears the stack. SO XX ,SAY, WILL CLEAR THE STACK."ByoБж1045:Бж1065BЖt:Гpage 4CQyЮ:З:З"TO EXTEND THE SYSTEM":З б(32,"-");:З"* FIND UNNEEDED WORD IN LINE 2.":З:З"* REPLACE WITH YOUR WORD.":З:З"* RUN AND EXECUTE: SOURCE (YOUR WORD).":З"* PUT YOUR WORD'S SUBROUTINE THERE."Cu~З"* GIVE A COPY TO A FRIEND.":ЗCзГЗ@416," TO REPEAT INSTRUCTIONS,ELSE forth"CяИKEY$│ Т:ЕKEY$│""з1160 :ДЕ KEY$│"R"з1025 :Д830::Гend of instructionsC·Н:ГlogoDТЮ:З" WELCOME TO FORTH CITY!"D]Ч╔"T5O3 L4CL8CCL4C L8CCL4EL8EEL4E L8EEL4G L8GGL4G L8GGL1O4C"DОЬЮ:З" YOU'RE ON!";:А TI│1 е 700:Л TI:ЮDФбРIONS,ELSE forth"CяИKEY$│ Т:ЕKEY$│""з1160 :ДЕ KEY$│"R"з1025 :Д830::Гend of instructionsC·Н:ГlogoDТ