Home » CEEFAX disks » telesoftware1.adl » Utils/ANAGRAM

Utils/ANAGRAM

This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.

Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.

Tape/disk: Home » CEEFAX disks » telesoftware1.adl
Filename: Utils/ANAGRAM
Read OK:
File size: 29F5 bytes
Load address: 1A00
Exec address: 801F
File contents
   10 REM ANAGRAM (c) D.J. Aldous. January 1986
   20 REM anagram generator, random or  systematic.
   30 ONERROR PROC_error
   40 MODE4
   50 VDU15
   60 PROC_LOGO
   70 MODE7
   80 VDU12,23;8202;0;0;0;
   90 I=INKEY(50)
  100 CLS
  110 PRINTTAB(10,11);CHR$131;CHR$141;"A N A G R A M":PRINTTAB(10,12);CHR$131;CHR$141;"A N A G R A M"
  120 PRINTTAB(10,14);CHR$134;"by  D.J. Aldous"
  130 I=INKEY(400)
  140 CLS
  150 PRINT''
  160 PRINTTAB(12);CHR$131;"A N A G R A M";
  170 PRINT'
  180 L%=40
  190 F$="This program generates anagrams or (more correctly), permutations of the letters of a word."
  200 PROCWORD_WRAP(F$,L%)
  210 PRINT'
  220 PRINT"You have the choice of two generators:"
  230 PRINTTAB(9);CHR$133;"Random";CHR$135;"or";CHR$132;"Systematic."
  240 PRINT';
  250 F$="The first will generate permutations  of ANY word in a random manner."
  260 PROCWORD_WRAP(F$,L%)
  270 PRINT'
  280 F$="The second will produce all possible permutations of any word of up to 9 letters in length in a systematic manner, starting with the word itself and ending with its inverse."
  290 PROCWORD_WRAP(F$,L%)
  300 PRINT': PRINTTAB(12);CHR$131;"M A R G A N A"
  310 PROC_CONTINUE
  320 PRINT'''''
  330 F$="In each case you have the options of :-"
  340 PROCWORD_WRAP(F$,L%)
  350 PRINT'
  360 F$="Generating the anagrams one by one, using the Space bar, or continuously."
  370 PROCWORD_WRAP(F$,L%)
  380 PRINT'
  390 F$="If continuously, of paging the output or not."
  400 PROCWORD_WRAP(F$,L%)
  410 PRINT'
  420 F$="Printing the anagrams, or not."
  430 PROCWORD_WRAP(F$,L%)
  440 PRINT'
  450 F$="Testing the program to see how long it takes to find a specified anagram, or not."
  460 PROCWORD_WRAP(F$,L%)
  470 PROC_CONTINUE
  480 PRINT'''''
  490 F$="If printing, note that it is likely to use a great deal of paper for a long word; in the Systematic mode, some indication of this is given by the Factorials data that follows."
  500 PROCWORD_WRAP(F$,L%)
  510 PRINT'
  520 F$="In the Random mode, if searching for a specified anagram, it may be found instantly or almost never; if not searching, it WILL run for ever !"
  530 PROCWORD_WRAP(F$,L%)
  540 PRINT'
  550 F$="Housewives and Bank Managers beware."
  560 PROCWORD_WRAP(F$,L%)
  570 PROC_CONTINUE
  580 PRINT'''''''
  590 F$="For a serial, rather than a parallel printer delete the REM in line 1670.                                            To see the Random generator at work delete the REM in line 4090."
  600 PROCWORD_WRAP(F$,L%)
  610 PROC_CONTINUE
  620 PRINTTAB(10,4);CHR$131;"Crossword solvers"
  630 PRINT
  640 F$="Do not expect the program to find unknown anagrams for you.              But it will help.                    Churn them out slowly - or print 'em. Study the various combinations of letters, and inspiration will surely follow."
  650 PROCWORD_WRAP(F$,L%)
  660 PRINT'
  670 PRINT"Try -"
  680 PRINT"ORCHESTRA/CARTHORSE.           Fun !"
  690 PRINT'"or -"
  700 PRINT"POST/STOP/OPTS/"
  710 PRINT"POTS/SPOT/TOPS.             Cheaper."
  720 PROC_CONTINUE
  730 PROC_FACTORIALS
  740 VDU23;29194;0;0;0;
  750 AN$="":WORD$="":F%=1:G$="":P$="":find$="":ans$="":paged%=0:run%=0:timed%=0:print%=0
  760 PROC_SYSRAND
  770 PROC_ENTER
  780 PROC_OUTPUT
  790 PROC_TEST
  800 PROC_PRINT
  810 PRINT
  820 IF timed% INPUT"Enter your chosen anagram ";find$
  830 PROC_CONTINUE
  840 VDU12,23;8202;0;0;0;
  850 IF run%=0 PROC_SINGLE:PROC_CONTINUE
  860 word$=WORD$: CLS
  870 IF print% VDU2
  880 IF print% AND run% VDU1,27,1,78,1,6
  890 PRINTTAB(14,1)"Anagrams of ";CHR$131;WORD$
  900 PRINT
  910 TIME=0
  920 IF syst% THEN PROC_System ELSE PROC_Random
  930 
  940 VDU3,15: PRINT'
  950 PROC_AGAIN
  960 CLS
  970 PROC_TITLE("B Y E  B Y E",131)
  980 VDU23;29194;0;0;0;
  990 END
 1000 DEFPROC_System
 1010 PRINT;
 1020 c$="":b$="":a$="":A$="":B$="":C$="":D$="":E$="":F$=""
 1030 F$=MID$(WORD$,l%,1)
 1040 E$=MID$(WORD$,l%-1,1):IF l%=2 THEN 1270
 1050 D$=MID$(WORD$,l%-2,1):IF l%=3 THEN 1250
 1060 C$=MID$(WORD$,l%-3,1):IF l%=4 THEN 1230
 1070 B$=MID$(WORD$,l%-4,1):IF l%=5 THEN 1210
 1080 A$=MID$(WORD$,l%-5,1):IF l%=6 THEN 1190
 1090 a$=MID$(WORD$,l%-6,1):IF l%=7 THEN 1170
 1100 b$=MID$(WORD$,l%-7,1):IF l%=8 THEN 1150
 1110 c$=MID$(WORD$,l%-8,1)
 1120FOR G%=1 TO 9
 1130AN$=""
 1140AN$=AN$+c$
 1150FOR H%=1 TO 8
 1160AN$=AN$+b$
 1170 FOR I%=1 TO 7
 1180 AN$=AN$+a$
 1190 FOR J%=1 TO 6
 1200 AN$=AN$+A$
 1210 FOR K%=1 TO 5
 1220 AN$=AN$+B$
 1230 FOR L%=1 TO 4
 1240 AN$=AN$+C$
 1250 FOR M%=1 TO 3
 1260 AN$=AN$+D$
 1270FOR N%=1 TO 2
 1280AN$=AN$+E$
 1290AN$=AN$+F$
 1300 PRINTTAB(15)F%;"  ";AN$ : F%=F%+1
 1310 PROC_find
 1320 IF run%=0 PROC_NEXT
 1330 IF run% AND paged% AND F%MOD21=0 PROC_SHIFT
 1340Z$=E$ : E$=F$ : F$=Z$
 1350 AN$=c$+b$+a$+A$+B$+C$+D$
 1360 NEXT N%
 1370 IF l%=2 GOTO 1640
 1380 Z$=D$ : D$=E$ : E$=F$ : F$=Z$
 1390 AN$=c$+b$+a$+A$+B$+C$
 1400 NEXT M%
 1410 IF l%=3 GOTO 1640
 1420 Z$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
 1430 AN$=c$+b$+a$+A$+B$
 1440 NEXT L%
 1450 IF l%=4 GOTO 1640
 1460 Z$=B$ : B$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
 1470 AN$=c$+b$+a$+A$
 1480 NEXT K%
 1490 IF l%=5 GOTO 1640
 1500 Z$=A$ : A$=B$ : B$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
 1510 AN$=c$+b$+a$
 1520 NEXT J%
 1530 IF l%=6 GOTO 1640
 1540 Z$=a$ : a$=A$ : A$=B$ : B$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
 1550 AN$=c$+b$
 1560 NEXT I%
 1570IF l%=7 GOTO 1640
 1580Z$=b$:b$=a$:a$=A$ : A$=B$ : B$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
 1590AN$=c$
 1600NEXT H%
 1610IF l%=8 GOTO 1640
 1620Z$=c$:c$=b$:b$=a$:a$=A$ : A$=B$ : B$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
 1630NEXT G%
 1640 IF timed%=0 PRINT'"That's the lot."':VDU7
 1650 ENDPROC
 1660 DEFPROC_PRINT
 1670 REM *FX5,2
 1680 REPEAT
 1690 PRINT'"Do you wish to";CHR$129;"print"
 1700 PRINT"the anagrams ? (Y/N)";
 1710 G$=GET$
 1720 UNTIL G$="Y" OR G$="y" OR G$="N" OR G$="n"
 1730 PRINTTAB(34);CHR$129;G$
 1740 IF G$="N" OR G$="n" ENDPROC
 1750 REPEAT
 1760 PRINT
 1770 PRINTCHR$129;"Are you SURE ?      (Y/N)";
 1780 G$=GET$
 1790 UNTIL G$="Y" OR G$="y" OR G$="N" OR G$="n"
 1800 PRINTTAB(34);CHR$129;G$
 1810 IF G$="Y" OR G$="y" print%=-1
 1820 IF G$="N" OR G$="n" print%=0: ENDPROC
 1830 REPEAT
 1840 PRINT'"Press 'P' when printer ready";
 1850 G$=GET$
 1860 UNTIL G$="P" OR G$="p"
 1870 PRINTTAB(35)G$
 1880 IF run% VDU2,1,27,1,78,1,6,3
 1890 ENDPROC
 1900 DEFPROC_OUTPUT
 1910 REPEAT
 1920 PRINT'"Do you want a";CHR$131;"running output"
 1930 PRINT"of the anagrams ?      (Y/N)";
 1940 G$=GET$
 1950 UNTIL G$="Y" OR G$="y" OR G$="N" OR G$="n"
 1960 PRINTTAB(34);CHR$131;G$
 1970 IF G$="Y" OR G$="y" THEN run%=-1: PROC_PAGE: ENDPROC: ELSE run%=0
 1980 ENDPROC
 1990 DEFPROC_TEST
 2000 REPEAT
 2010 PRINT'"Do you wish to";CHR$134;"test";CHR$135;"the program,"
 2020 PRINT"to see how long it takes to find"
 2030 PRINT"one particular anagram ?   (Y/N)";
 2040 G$=GET$
 2050 UNTIL G$="Y" OR G$="y" OR G$="N" OR G$="n"
 2060 PRINTTAB(34);CHR$134;G$
 2070 IF G$="Y" OR G$="y" THEN timed%=-1 ELSE timed%=0
 2080 ENDPROC
 2090 DEFPROC_NEXT
 2100 REPEAT
 2110 G$=GET$
 2120 UNTIL G$=" " OR G$="W" OR G$="w"
 2130 IF G$="W" OR G$="w" THEN PRINT: PRINTTAB(27)word$: PRINT: PROC_NEXT
 2140 ENDPROC
 2150 DEFPROC_ENTER
 2160 PRINT
 2170 IF syst%=0 GOTO 2210
 2180REPEAT
 2190 PRINT"Enter word            ";:INPUT WORD$
 2200UNTIL LEN(WORD$)<10: GOTO 2220
 2210 PRINT"Enter word            ";:INPUT WORD$
 2220 l%=LEN(WORD$)
 2230ENDPROC
 2240 DEFPROC_SINGLE
 2250 PRINT'
 2260 PRINTTAB(3,11)"Press SPACE for the next anagram"
 2270 PRINTTAB(3,13)"Press 'W' for the original word."
 2280 ENDPROC
 2290 DEFPROC_PAGE
 2300 REPEAT
 2310 PRINT'"Do you want the continuous"
 2320 PRINT"list to be";CHR$130;"paged";CHR$135;"?   (Y/N)";
 2330 G$=GET$
 2340 UNTIL G$="Y" OR G$="y" OR G$="N" OR G$="n"
 2350 PRINTTAB(34);CHR$130;G$
 2360 IF G$="Y" OR G$="y" THEN VDU14: paged%=-1: ENDPROC: ELSE paged%=0
 2370 ENDPROC
 2380 DEFPROC_SHIFT
 2390 PRINT"Press SHIFT"
 2400 PRINT"to continue"
 2410 ENDPROC
 2420 DEFPROCWORD_WRAP(P$,L%)
 2430 LOCAL word$, I, done
 2440 done=0
 2450 REPEAT
 2460 I = INSTR(P$," ")
 2470 word$ = LEFT$(P$,I)
 2480 P$= RIGHT$(P$,LEN P$-I)
 2490 IF P$= "" done=-1
 2500 IF I=0 word$=P$: done=-1
 2510 IF LEN word$>L%-COUNT PRINT
 2520 PRINT word$;
 2530 UNTIL done
 2540 ENDPROC
 2550 DEFPROC_CONTINUE
 2560 REPEAT
 2570 PRINTTAB(7,24);CHR$(130);"Press SPACE to continue";
 2580 UNTIL GET$=" "
 2590CLS
 2600ENDPROC
 2610 DEFPROC_TITLE(T$,Y%)
 2620 VDU12,23;8202;0;0;0;
 2630 LOCAL Q%
 2640 Q% = 18-(LEN(T$)/2)
 2650 FOR I%=11 TO 12:PRINTTAB(Q%,I%);CHR$(Y%);CHR$(141);T$:NEXT
 2660 I=INKEY(400)
 2670 CLS
 2680 ENDPROC
 2690 DEFPROC_FACTORIALS
 2700 CLS
 2710 PRINT'"The number of permutations of a word is the factorial of its number of letters -";
 2720 PRINT"a three-letter word has 3x2x1 = 6       permutations, etc. Thus:"
 2730 PRINTTAB(27)"Approx time,"
 2740 PRINTTAB(27)" Systematic"
 2750 PRINTTAB(27)"  program"
 2760 PRINTTAB(27)"  running"
 2770 PRINT"No. of ltrs.";TAB(13)"Permutations";TAB(27)"continuously"
 2780 PRINT"____________";TAB(13)"____________";TAB(27)"____________"
 2790 PRINTTAB(6)"2";TAB(22)"2";TAB(28)" 0.1  secs"
 2800 PRINTTAB(6)"3";TAB(22)"6";TAB(28)" 0.25 secs"
 2810 PRINTTAB(6)"4";TAB(21)"24";TAB(28)" 1    sec"
 2820 PRINTTAB(6)"5";TAB(20)"120";TAB(28)" 5    secs"
 2830 PRINTTAB(6)"6";TAB(20)"720";TAB(28)"27    secs"
 2840 PRINTTAB(6)"7";TAB(18)"5,040";TAB(28)" 3    mins"
 2850 PRINTTAB(6)"8";TAB(17)"40,320";TAB(28)"21.5  mins"
 2860 PRINTTAB(6)"9";TAB(16)"362,880";TAB(28)" 3.3  hrs"
 2870 PRINT'"Any other program mode is of course muchslower, as is printing."
 2880 PROC_CONTINUE
 2890 ENDPROC
 2900 DEFPROC_AGAIN
 2910 VDU3
 2920 REPEAT
 2930 PRINTTAB(9,24);CHR$(130);"Another word ?  (Y/N)";
 2940 G$=GET$
 2950 UNTIL G$="Y" OR G$="y" OR G$="N"  OR G$="n"
 2960 IF G$="Y" OR G$="y" THEN CLS: GOTO 740: ELSE GOTO 960
 2970ENDPROC
 2980 DEFPROC_LOGO
 2990 VDU12,23;8202;0;0;0;
 3000 VDU19,128,135;0;
 3010 VDU19,1,2;0;
 3020 PLOT4,160,128
 3030 PLOT5,160,896
 3040 PLOT5,1120,896
 3050 PLOT5,1120,128
 3060 PLOT5,160,128
 3070 PLOT4,162,132
 3080 PLOT5,162,892
 3090 PLOT5,1118,892
 3100 PLOT5,1118,132
 3110 PLOT5,162,132
 3120 PLOT0,2,0
 3130 PLOT5,164,892
 3140 PLOT4,1116,892
 3150 PLOT5,1116,132
 3160 PLOT0,0,4
 3170 PLOT5,164,136
 3180 PLOT5,164,888
 3190 PLOT5,1116,888
 3200 PLOT5,1116,136
 3210 PLOT0,-2,0
 3220 PLOT5,1114,888
 3230 PLOT4,168,888
 3240 PLOT5,168,136
 3250 VDU29,600;700;
 3260 PLOT4,0,0
 3270 RESTORE
 3280 READ X%,Y%
 3290 PLOT4,X%,Y%
 3300 I=INKEY(5)
 3310 READ X%,Y%
 3320 PLOT85,X%,Y%
 3330 I=INKEY(5)
 3340 P%=0
 3350 FOR P%=1 TO 24
 3360 PLOT4,0,0
 3370 READ X%,Y%
 3380 PLOT85,X%,Y%
 3390 I=INKEY(5)
 3400 READ X%,Y%
 3410 PLOT85,X%,Y%
 3420 I=INKEY(5)
 3430 NEXT
 3440 PLOT4,0,0
 3450 READ X%,Y%
 3460 PLOT85,X%,Y%
 3470 I=INKEY(5)
 3480PLOT4,-60,-175
 3490P%=0
 3500 RESTORE 3720
 3510FOR P%=1TO9
 3520READ X%,Y%
 3530PLOT5,X%,Y%
 3540NEXT
 3550PLOT4,150,-198
 3560P%=0
 3570RESTORE 3730
 3580FORP%=1TO8
 3590READ X%,Y%
 3600PLOT 5,X%,Y%
 3610NEXT
 3620 PLOT4,4,-150
 3630 PLOT5,24,-175
 3640 PLOT5,50,-212
 3650 PLOT5,72,-168
 3660 PLOT4,-94,-400
 3670 PLOT5,236,-400
 3680 PLOT0,-4,0
 3690 PLOT5,-94,-400
 3700 DATA0,125,25,112,50,100,75,87,100,90,125,100,150,110,175,100,200,94,225,75,250,25,250,0,250,-25,237,-50,248,-75,272,-100,284,-125,276,-150,220,-175,200,-188,175,-192,150,-198,125,-200,100,-205,75,-175,50,-182,25,-164,0,-150
 3710 DATA-25,-156,-50,-175,-75,-216,-100,-226,-125,-226,-150,-218,-175,-188,-180,-150,-184,-125,-186,-100,-180,-75,-170,-50,-160,-25,-140,0,-140,25,-150,50,-136,75,-125,80,-100,90,-75,112,-50,124,-25,128,0,125
 3720 DATA-20,-200,0,-225,12,-250,24,-275,24,-300,24,-325,24,-350,24,-375,18,-400
 3730 DATA120,-225,110,-250,104,-275,104,-300,104,-325,104,-350,116,-375,120,-400
 3740 I=INKEY(150)
 3750 PRINTTAB(13,24);"B R O A D  O A K"
 3760 I=INKEY(300)
 3770 VDU30
 3780 VDU23;29194;0;0;0;
 3790 ENDPROC
 3800 DEFPROC_time
 3810 LOCAL t,s,s%,m%,h%
 3820 t=TIME:s=t/100:s%=INT(s):m%=INT(t/6000):h%=INT(t/360000)
 3830 IF s%<60 PRINT'"Time taken = ";s;" seconds."
 3840 IF s%>=60 AND m%<60 PRINT'"Time taken = ";m%;" minute(s) ";s%MOD60;" sec(s)."
 3850 IF m%>=60 PRINT'"Time taken = ";h%;" hour(s) ";m%MOD60;" min(s) ";s%MOD60;" sec(s)."
 3860 ENDPROC
 3870 DEFPROC_SYSRAND
 3880 REPEAT
 3890 PRINT'"Do you want the";CHR$133;"Random";CHR$135;"or the"
 3900 PRINTCHR$132;"Systematic";CHR$135;"generator ? (R/S)";
 3910 G$=GET$
 3920 UNTIL G$="S" OR G$="s" OR G$="R" OR G$="r"
 3930 IF G$="S" OR G$="s" THEN syst%=-1: PRINTTAB(34);CHR$132;G$: ELSE syst%=0: PRINTTAB(34);CHR$133;G$
 3940 ENDPROC
 3950 
 3960 DEFPROC_find
 3970 IF AN$=find$ AND timed% VDU7: PRINTCHR$131;CHR$136;AN$: PRINT'"There's your";CHR$131;"anagram";CHR$135;"!": PROC_time: PROC_AGAIN
 3980 ENDPROC
 3990 DEFPROC_Random
 4000 LOCAL l%,X%
 4010 l%=LEN(WORD$)
 4020 REPEAT
 4030 rand%=(l%+1)*RND(1)
 4040 IF rand%<1 GOTO 4030
 4050 FOR X%=1 TO l%
 4060 a$=RIGHT$(WORD$,l%-rand%):b$=MID$(WORD$,rand%,1):c$=LEFT$(WORD$,rand%-1)
 4070 AN$=a$+b$+c$
 4080 NEXT X%
 4090 REM PROCdisplay_random
 4100 PRINTTAB(15)F%;"  ";AN$
 4110 F%=F%+1
 4120 PROC_find
 4130 IF run%=0 PROC_NEXT
 4140 IF run% AND paged% AND F%MOD21=0 PROC_SHIFT
 4150 WORD$=AN$
 4160 UNTIL FALSE
 4170 ENDPROC
 4180 DEFPROC_error
 4190 VDU3
 4200 IF ERR=17 THEN VDU3,15: CLS: GOTO 950 ELSE REPORT: END
 4210 ENDPROC
 4220 DEFPROCdisplay_random
 4230 PRINT'"Random no.= ";rand%: I=INKEY(40)
 4240 PRINT"RIGHT$    = ";a$: I=INKEY(40)
 4250 PRINT"MID$      = ";b$: I=INKEY(40)
 4260 PRINT"LEFT$     = ";c$: I=INKEY(40)
 4270 PRINT"word$";"     = ";a$;"+";b$;"+";c$: I=INKEY(40)
 4280 ENDPROC

, � ANAGRAM (c) D.J. Aldous. January 1986
0 � anagram generator, random or  systematic.
 � �_error
( �4
2 �15
< �_LOGO
F �7
P �12,23;8202;0;0;0;
Z I=�(50)
d �
nJ �10,11);�131;�141;"A N A G R A M":�10,12);�131;�141;"A N A G R A M"
x$ �10,14);�134;"by  D.J. Aldous"
�
 I=�(400)
� �
� �''
�  �12);�131;"A N A G R A M";
� �'
�
 L%=40
�e F$="This program generates anagrams or (more correctly), permutations of the letters of a word."
� �WORD_WRAP(F$,L%)
� �'
�. �"You have the choice of two generators:"
�4 �9);�133;"Random";�135;"or";�132;"Systematic."
� �';
�O F$="The first will generate permutations  of ANY word in a random manner."
 �WORD_WRAP(F$,L%)
 �'
� F$="The second will produce all possible permutations of any word of up to 9 letters in length in a systematic manner, starting with the word itself and ending with its inverse."
" �WORD_WRAP(F$,L%)
,# �': �12);�131;"M A R G A N A"
6 �_CONTINUE
@ �'''''
J1 F$="In each case you have the options of :-"
T �WORD_WRAP(F$,L%)
^ �'
hS F$="Generating the anagrams one by one, using the Space bar, or continuously."
r �WORD_WRAP(F$,L%)
| �'
�7 F$="If continuously, of paging the output or not."
� �WORD_WRAP(F$,L%)
� �'
�( F$="Printing the anagrams, or not."
� �WORD_WRAP(F$,L%)
� �'
�[ F$="Testing the program to see how long it takes to find a specified anagram, or not."
� �WORD_WRAP(F$,L%)
� �_CONTINUE
� �'''''
� F$="If printing, note that it is likely to use a great deal of paper for a long word; in the Systematic mode, some indication of this is given by the Factorials data that follows."
� �WORD_WRAP(F$,L%)
� �'
� F$="In the Random mode, if searching for a specified anagram, it may be found instantly or almost never; if not searching, it WILL run for ever !"
 �WORD_WRAP(F$,L%)
 �'
&. F$="Housewives and Bank Managers beware."
0 �WORD_WRAP(F$,L%)
: �_CONTINUE
D
 �'''''''
N� F$="For a serial, rather than a parallel printer delete the REM in line 1670.                                            To see the Random generator at work delete the REM in line 4090."
X �WORD_WRAP(F$,L%)
b �_CONTINUE
l% �10,4);�131;"Crossword solvers"
v �
�� F$="Do not expect the program to find unknown anagrams for you.              But it will help.                    Churn them out slowly - or print 'em. Study the various combinations of letters, and inspiration will surely follow."
� �WORD_WRAP(F$,L%)
� �'
�
 �"Try -"
�, �"ORCHESTRA/CARTHORSE.           Fun !"
�
 �'"or -"
� �"POST/STOP/OPTS/"
�, �"POTS/SPOT/TOPS.             Cheaper."
� �_CONTINUE
� �_FACTORIALS
� �23;29194;0;0;0;
�X AN$="":WORD$="":F%=1:G$="":P$="":find$="":ans$="":paged%=0:run%=0:timed%=0:print%=0
� �_SYSRAND
 �_ENTER

 �_OUTPUT
 �_TEST
  �_PRINT
* �
41 � timed% �"Enter your chosen anagram ";find$
> �_CONTINUE
H �12,23;8202;0;0;0;
R! � run%=0 �_SINGLE:�_CONTINUE
\ word$=WORD$: �
f � print% �2
p# � print% � run% �1,27,1,78,1,6
z% �14,1)"Anagrams of ";�131;WORD$
� �
� �=0
�" � syst% � �_System � �_Random
� 
� �3,15: �'
� �_AGAIN
� �
�  �_TITLE("B Y E  B Y E",131)
� �23;29194;0;0;0;
� �
� ��_System
� �;
�: c$="":b$="":a$="":A$="":B$="":C$="":D$="":E$="":F$=""
 F$=�WORD$,l%,1)
$ E$=�WORD$,l%-1,1):� l%=2 � �dvD
$ D$=�WORD$,l%-2,1):� l%=3 � �dbD
$$ C$=�WORD$,l%-3,1):� l%=4 � �dND
.$ B$=�WORD$,l%-4,1):� l%=5 � �tzD
8$ A$=�WORD$,l%-5,1):� l%=6 � �tfD
B$ a$=�WORD$,l%-6,1):� l%=7 � �tRD
L$ b$=�WORD$,l%-7,1):� l%=8 � �D~D
V c$=�WORD$,l%-8,1)
`� G%=1 � 9
j
AN$=""
tAN$=AN$+c$
~� H%=1 � 8
�AN$=AN$+b$
� � I%=1 � 7
� AN$=AN$+a$
� � J%=1 � 6
� AN$=AN$+A$
� � K%=1 � 5
� AN$=AN$+B$
� � L%=1 � 4
� AN$=AN$+C$
� � M%=1 � 3
� AN$=AN$+D$
�� N%=1 � 2
AN$=AN$+E$

AN$=AN$+F$
 �15)F%;"  ";AN$ : F%=F%+1
 �_find
( � run%=0 �_NEXT
2& � run% � paged% � F%�21=0 �_SHIFT
<Z$=E$ : E$=F$ : F$=Z$
F AN$=c$+b$+a$+A$+B$+C$+D$
P	 � N%
Z � l%=2 � �DhF
d" Z$=D$ : D$=E$ : E$=F$ : F$=Z$
n AN$=c$+b$+a$+A$+B$+C$
x	 � M%
� � l%=3 � �DhF
�* Z$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
� AN$=c$+b$+a$+A$+B$
�	 � L%
� � l%=4 � �DhF
�2 Z$=B$ : B$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
� AN$=c$+b$+a$+A$
�	 � K%
� � l%=5 � �DhF
�: Z$=A$ : A$=B$ : B$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
� AN$=c$+b$+a$
�	 � J%
� � l%=6 � �DhF
B Z$=a$ : a$=A$ : A$=B$ : B$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
 AN$=c$+b$
	 � I%
"� l%=7 � �DhF
,EZ$=b$:b$=a$:a$=A$ : A$=B$ : B$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
6
AN$=c$
@� H%
J� l%=8 � �DhF
TKZ$=c$:c$=b$:b$=a$:a$=A$ : A$=B$ : B$=C$ : C$=D$ : D$=E$ : E$=F$ : F$=Z$
^� G%
h' � timed%=0 �'"That's the lot."':�7
r �
|
 ��_PRINT
�
 � *FX5,2
� �
�$ �'"Do you wish to";�129;"print"
� �"the anagrams ? (Y/N)";
�	 G$=�
�( � G$="Y" � G$="y" � G$="N" � G$="n"
� �34);�129;G$
� � G$="N" � G$="n" �
� �
� �
�' �129;"Are you SURE ?      (Y/N)";
�	 G$=�
�( � G$="Y" � G$="y" � G$="N" � G$="n"
 �34);�129;G$
  � G$="Y" � G$="y" print%=-1
" � G$="N" � G$="n" print%=0: �
& �
0& �'"Press 'P' when printer ready";
:	 G$=�
D � G$="P" � G$="p"
N �35)G$
X � run% �2,1,27,1,78,1,6,3
b �
l ��_OUTPUT
v �
�, �'"Do you want a";�131;"running output"
�% �"of the anagrams ?      (Y/N)";
�	 G$=�
�( � G$="Y" � G$="y" � G$="N" � G$="n"
� �34);�131;G$
�5 � G$="Y" � G$="y" � run%=-1: �_PAGE: �: � run%=0
� �
� ��_TEST
� �
�7 �'"Do you wish to";�134;"test";�135;"the program,"
�( �"to see how long it takes to find"
�) �"one particular anagram ?   (Y/N)";
�	 G$=�
( � G$="Y" � G$="y" � G$="N" � G$="n"
 �34);�134;G$
- � G$="Y" � G$="y" � timed%=-1 � timed%=0
  �
* ��_NEXT
4 �
>	 G$=�
H � G$=" " � G$="W" � G$="w"
R1 � G$="W" � G$="w" � �: �27)word$: �: �_NEXT
\ �
f
 ��_ENTER
p �
z � syst%=0 � �tbH
��
�' �"Enter word            ";:� WORD$
�� �(WORD$)<10: � �tlH
�' �"Enter word            ";:� WORD$
� l%=�(WORD$)
��
� ��_SINGLE
� �'
�. �3,11)"Press SPACE for the next anagram"
�. �3,13)"Press 'W' for the original word."
� �
� ��_PAGE
� �
	# �'"Do you want the continuous"
	1 �"list to be";�130;"paged";�135;"?   (Y/N)";
		 G$=�
	$( � G$="Y" � G$="y" � G$="N" � G$="n"
	. �34);�130;G$
	86 � G$="Y" � G$="y" � �14: paged%=-1: �: � paged%=0
	B �
	L
 ��_SHIFT
	V �"Press SHIFT"
	` �"to continue"
	j �
	t ��WORD_WRAP(P$,L%)
	~ � word$, I, done
	� done=0
	� �
	� I = �P$," ")
	� word$ = �P$,I)
	� P$= �P$,� P$-I)
	� � P$= "" done=-1
	� � I=0 word$=P$: done=-1
	� � � word$>L%-� �
	�
 � word$;
	� � done
	� �
	� ��_CONTINUE
 �

. �7,24);�(130);"Press SPACE to continue";
 � �=" "
�
(�
2 ��_TITLE(T$,Y%)
< �12,23;8202;0;0;0;
F	 � Q%
P Q% = 18-(�(T$)/2)
Z, � I%=11 � 12:�Q%,I%);�(Y%);�(141);T$:�
d
 I=�(400)
n �
x �
� ��_FACTORIALS
� �
�Z �'"The number of permutations of a word is the factorial of its number of letters -";
�H �"a three-letter word has 3x2x1 = 6       permutations, etc. Thus:"
� �27)"Approx time,"
� �27)" Systematic"
� �27)"  program"
� �27)"  running"
�: �"No. of ltrs.";�13)"Permutations";�27)"continuously"
�: �"____________";�13)"____________";�27)"____________"
�% �6)"2";�22)"2";�28)" 0.1  secs"
�% �6)"3";�22)"6";�28)" 0.25 secs"
�% �6)"4";�21)"24";�28)" 1    sec"
' �6)"5";�20)"120";�28)" 5    secs"
' �6)"6";�20)"720";�28)"27    secs"
) �6)"7";�18)"5,040";�28)" 3    mins"
"* �6)"8";�17)"40,320";�28)"21.5  mins"
,* �6)"9";�16)"362,880";�28)" 3.3  hrs"
6H �'"Any other program mode is of course muchslower, as is printing."
@ �_CONTINUE
J �
T
 ��_AGAIN
^ �3
h �
r, �9,24);�(130);"Another word ?  (Y/N)";
|	 G$=�
�) � G$="Y" � G$="y" � G$="N"  � G$="n"
�, � G$="Y" � G$="y" � �: � �ddB: � � �d@C
��
� ��_LOGO
� �12,23;8202;0;0;0;
� �19,128,135;0;
� �19,1,2;0;
� �4,160,128
� �5,160,896
� �5,1120,896
� �5,1120,128
� �5,160,128
� �4,162,132
 �5,162,892
 �5,1118,892
 �5,1118,132
& �5,162,132
0 �0,2,0
: �5,164,892
D �4,1116,892
N �5,1116,132
X �0,0,4
b �5,164,136
l �5,164,888
v �5,1116,888
� �5,1116,136
� �0,-2,0
� �5,1114,888
� �4,168,888
� �5,168,136
� �29,600;700;
� �4,0,0
� �
� � X%,Y%
�
 �4,X%,Y%
� I=�(5)
� � X%,Y%
� �85,X%,Y%

 I=�(5)

	 P%=0

 � P%=1 � 24

  �4,0,0

* � X%,Y%

4 �85,X%,Y%

> I=�(5)

H � X%,Y%

R �85,X%,Y%

\ I=�(5)

f �

p �4,0,0

z � X%,Y%

� �85,X%,Y%

� I=�(5)

��4,-60,-175

�P%=0

� � �tHN

�� P%=1�9

�� X%,Y%

��5,X%,Y%

��

��4,150,-198

�P%=0

�
� �tRN

��P%=1�8
� X%,Y%

� 5,X%,Y%
�
$ �4,4,-150
. �5,24,-175
8 �5,50,-212
B �5,72,-168
L �4,-94,-400
V �5,236,-400
` �0,-4,0
j �5,-94,-400
t� �0,125,25,112,50,100,75,87,100,90,125,100,150,110,175,100,200,94,225,75,250,25,250,0,250,-25,237,-50,248,-75,272,-100,284,-125,276,-150,220,-175,200,-188,175,-192,150,-198,125,-200,100,-205,75,-175,50,-182,25,-164,0,-150
~� �-25,-156,-50,-175,-75,-216,-100,-226,-125,-226,-150,-218,-175,-188,-180,-150,-184,-125,-186,-100,-180,-75,-170,-50,-160,-25,-140,0,-140,25,-150,50,-136,75,-125,80,-100,90,-75,112,-50,124,-25,128,0,125
�M �-20,-200,0,-225,12,-250,24,-275,24,-300,24,-325,24,-350,24,-375,18,-400
�M �120,-225,110,-250,104,-275,104,-300,104,-325,104,-350,116,-375,120,-400
�
 I=�(150)
�  �13,24);"B R O A D  O A K"
�
 I=�(300)
� �30
� �23;29194;0;0;0;
� �
� ��_time
� � t,s,s%,m%,h%
�4 t=�:s=t/100:s%=�(s):m%=�(t/6000):h%=�(t/360000)
�, � s%<60 �'"Time taken = ";s;" seconds."
I � s%>=60 � m%<60 �'"Time taken = ";m%;" minute(s) ";s%�60;" sec(s)."

P � m%>=60 �'"Time taken = ";h%;" hour(s) ";m%�60;" min(s) ";s%�60;" sec(s)."
 �
 ��_SYSRAND
( �
24 �'"Do you want the";�133;"Random";�135;"or the"
<1 �132;"Systematic";�135;"generator ? (R/S)";
F	 G$=�
P( � G$="S" � G$="s" � G$="R" � G$="r"
ZJ � G$="S" � G$="s" � syst%=-1: �34);�132;G$: � syst%=0: �34);�133;G$
d �
n 
x ��_find
�g � AN$=find$ � timed% �7: �131;�136;AN$: �'"There's your";�131;"anagram";�135;"!": �_time: �_AGAIN
� �
� ��_Random
� � l%,X%
� l%=�(WORD$)
� �
� rand%=(l%+1)*�(1)
� � rand%<1 � �t~O
� � X%=1 � l%
�> a$=�WORD$,l%-rand%):b$=�WORD$,rand%,1):c$=�WORD$,rand%-1)
� AN$=a$+b$+c$
�	 � X%
� � PROCdisplay_random
 �15)F%;"  ";AN$
 F%=F%+1
 �_find
" � run%=0 �_NEXT
,& � run% � paged% � F%�21=0 �_SHIFT
6 WORD$=AN$
@ � �
J �
T
 ��_error
^ �3
h% � �=17 � �3,15: �: � �tvC � �: �
r �
| ��display_random
�$ �'"Random no.= ";rand%: I=�(40)
�  �"RIGHT$    = ";a$: I=�(40)
�  �"MID$      = ";b$: I=�(40)
�  �"LEFT$     = ";c$: I=�(40)
�1 �"word$";"     = ";a$;"+";b$;"+";c$: I=�(40)
� �
�
00000000  0d 00 0a 2c 20 f4 20 41  4e 41 47 52 41 4d 20 28  |..., . ANAGRAM (|
00000010  63 29 20 44 2e 4a 2e 20  41 6c 64 6f 75 73 2e 20  |c) D.J. Aldous. |
00000020  4a 61 6e 75 61 72 79 20  31 39 38 36 0d 00 14 30  |January 1986...0|
00000030  20 f4 20 61 6e 61 67 72  61 6d 20 67 65 6e 65 72  | . anagram gener|
00000040  61 74 6f 72 2c 20 72 61  6e 64 6f 6d 20 6f 72 20  |ator, random or |
00000050  20 73 79 73 74 65 6d 61  74 69 63 2e 0d 00 1e 0f  | systematic.....|
00000060  20 ee 85 20 f2 5f 65 72  72 6f 72 0d 00 28 07 20  | .. ._error..(. |
00000070  eb 34 0d 00 32 08 20 ef  31 35 0d 00 3c 0b 20 f2  |.4..2. .15..<. .|
00000080  5f 4c 4f 47 4f 0d 00 46  07 20 eb 37 0d 00 50 17  |_LOGO..F. .7..P.|
00000090  20 ef 31 32 2c 32 33 3b  38 32 30 32 3b 30 3b 30  | .12,23;8202;0;0|
000000a0  3b 30 3b 0d 00 5a 0c 20  49 3d a6 28 35 30 29 0d  |;0;..Z. I=.(50).|
000000b0  00 64 06 20 db 0d 00 6e  4a 20 f1 8a 31 30 2c 31  |.d. ...nJ ..10,1|
000000c0  31 29 3b bd 31 33 31 3b  bd 31 34 31 3b 22 41 20  |1);.131;.141;"A |
000000d0  4e 20 41 20 47 20 52 20  41 20 4d 22 3a f1 8a 31  |N A G R A M":..1|
000000e0  30 2c 31 32 29 3b bd 31  33 31 3b bd 31 34 31 3b  |0,12);.131;.141;|
000000f0  22 41 20 4e 20 41 20 47  20 52 20 41 20 4d 22 0d  |"A N A G R A M".|
00000100  00 78 24 20 f1 8a 31 30  2c 31 34 29 3b bd 31 33  |.x$ ..10,14);.13|
00000110  34 3b 22 62 79 20 20 44  2e 4a 2e 20 41 6c 64 6f  |4;"by  D.J. Aldo|
00000120  75 73 22 0d 00 82 0d 20  49 3d a6 28 34 30 30 29  |us".... I=.(400)|
00000130  0d 00 8c 06 20 db 0d 00  96 08 20 f1 27 27 0d 00  |.... ..... .''..|
00000140  a0 20 20 f1 8a 31 32 29  3b bd 31 33 31 3b 22 41  |.  ..12);.131;"A|
00000150  20 4e 20 41 20 47 20 52  20 41 20 4d 22 3b 0d 00  | N A G R A M";..|
00000160  aa 07 20 f1 27 0d 00 b4  0a 20 4c 25 3d 34 30 0d  |.. .'.... L%=40.|
00000170  00 be 65 20 46 24 3d 22  54 68 69 73 20 70 72 6f  |..e F$="This pro|
00000180  67 72 61 6d 20 67 65 6e  65 72 61 74 65 73 20 61  |gram generates a|
00000190  6e 61 67 72 61 6d 73 20  6f 72 20 28 6d 6f 72 65  |nagrams or (more|
000001a0  20 63 6f 72 72 65 63 74  6c 79 29 2c 20 70 65 72  | correctly), per|
000001b0  6d 75 74 61 74 69 6f 6e  73 20 6f 66 20 74 68 65  |mutations of the|
000001c0  20 6c 65 74 74 65 72 73  20 6f 66 20 61 20 77 6f  | letters of a wo|
000001d0  72 64 2e 22 0d 00 c8 16  20 f2 57 4f 52 44 5f 57  |rd.".... .WORD_W|
000001e0  52 41 50 28 46 24 2c 4c  25 29 0d 00 d2 07 20 f1  |RAP(F$,L%).... .|
000001f0  27 0d 00 dc 2e 20 f1 22  59 6f 75 20 68 61 76 65  |'.... ."You have|
00000200  20 74 68 65 20 63 68 6f  69 63 65 20 6f 66 20 74  | the choice of t|
00000210  77 6f 20 67 65 6e 65 72  61 74 6f 72 73 3a 22 0d  |wo generators:".|
00000220  00 e6 34 20 f1 8a 39 29  3b bd 31 33 33 3b 22 52  |..4 ..9);.133;"R|
00000230  61 6e 64 6f 6d 22 3b bd  31 33 35 3b 22 6f 72 22  |andom";.135;"or"|
00000240  3b bd 31 33 32 3b 22 53  79 73 74 65 6d 61 74 69  |;.132;"Systemati|
00000250  63 2e 22 0d 00 f0 08 20  f1 27 3b 0d 00 fa 4f 20  |c.".... .';...O |
00000260  46 24 3d 22 54 68 65 20  66 69 72 73 74 20 77 69  |F$="The first wi|
00000270  6c 6c 20 67 65 6e 65 72  61 74 65 20 70 65 72 6d  |ll generate perm|
00000280  75 74 61 74 69 6f 6e 73  20 20 6f 66 20 41 4e 59  |utations  of ANY|
00000290  20 77 6f 72 64 20 69 6e  20 61 20 72 61 6e 64 6f  | word in a rando|
000002a0  6d 20 6d 61 6e 6e 65 72  2e 22 0d 01 04 16 20 f2  |m manner.".... .|
000002b0  57 4f 52 44 5f 57 52 41  50 28 46 24 2c 4c 25 29  |WORD_WRAP(F$,L%)|
000002c0  0d 01 0e 07 20 f1 27 0d  01 18 b7 20 46 24 3d 22  |.... .'.... F$="|
000002d0  54 68 65 20 73 65 63 6f  6e 64 20 77 69 6c 6c 20  |The second will |
000002e0  70 72 6f 64 75 63 65 20  61 6c 6c 20 70 6f 73 73  |produce all poss|
000002f0  69 62 6c 65 20 70 65 72  6d 75 74 61 74 69 6f 6e  |ible permutation|
00000300  73 20 6f 66 20 61 6e 79  20 77 6f 72 64 20 6f 66  |s of any word of|
00000310  20 75 70 20 74 6f 20 39  20 6c 65 74 74 65 72 73  | up to 9 letters|
00000320  20 69 6e 20 6c 65 6e 67  74 68 20 69 6e 20 61 20  | in length in a |
00000330  73 79 73 74 65 6d 61 74  69 63 20 6d 61 6e 6e 65  |systematic manne|
00000340  72 2c 20 73 74 61 72 74  69 6e 67 20 77 69 74 68  |r, starting with|
00000350  20 74 68 65 20 77 6f 72  64 20 69 74 73 65 6c 66  | the word itself|
00000360  20 61 6e 64 20 65 6e 64  69 6e 67 20 77 69 74 68  | and ending with|
00000370  20 69 74 73 20 69 6e 76  65 72 73 65 2e 22 0d 01  | its inverse."..|
00000380  22 16 20 f2 57 4f 52 44  5f 57 52 41 50 28 46 24  |". .WORD_WRAP(F$|
00000390  2c 4c 25 29 0d 01 2c 23  20 f1 27 3a 20 f1 8a 31  |,L%)..,# .': ..1|
000003a0  32 29 3b bd 31 33 31 3b  22 4d 20 41 20 52 20 47  |2);.131;"M A R G|
000003b0  20 41 20 4e 20 41 22 0d  01 36 0f 20 f2 5f 43 4f  | A N A"..6. ._CO|
000003c0  4e 54 49 4e 55 45 0d 01  40 0b 20 f1 27 27 27 27  |NTINUE..@. .''''|
000003d0  27 0d 01 4a 31 20 46 24  3d 22 49 6e 20 65 61 63  |'..J1 F$="In eac|
000003e0  68 20 63 61 73 65 20 79  6f 75 20 68 61 76 65 20  |h case you have |
000003f0  74 68 65 20 6f 70 74 69  6f 6e 73 20 6f 66 20 3a  |the options of :|
00000400  2d 22 0d 01 54 16 20 f2  57 4f 52 44 5f 57 52 41  |-"..T. .WORD_WRA|
00000410  50 28 46 24 2c 4c 25 29  0d 01 5e 07 20 f1 27 0d  |P(F$,L%)..^. .'.|
00000420  01 68 53 20 46 24 3d 22  47 65 6e 65 72 61 74 69  |.hS F$="Generati|
00000430  6e 67 20 74 68 65 20 61  6e 61 67 72 61 6d 73 20  |ng the anagrams |
00000440  6f 6e 65 20 62 79 20 6f  6e 65 2c 20 75 73 69 6e  |one by one, usin|
00000450  67 20 74 68 65 20 53 70  61 63 65 20 62 61 72 2c  |g the Space bar,|
00000460  20 6f 72 20 63 6f 6e 74  69 6e 75 6f 75 73 6c 79  | or continuously|
00000470  2e 22 0d 01 72 16 20 f2  57 4f 52 44 5f 57 52 41  |."..r. .WORD_WRA|
00000480  50 28 46 24 2c 4c 25 29  0d 01 7c 07 20 f1 27 0d  |P(F$,L%)..|. .'.|
00000490  01 86 37 20 46 24 3d 22  49 66 20 63 6f 6e 74 69  |..7 F$="If conti|
000004a0  6e 75 6f 75 73 6c 79 2c  20 6f 66 20 70 61 67 69  |nuously, of pagi|
000004b0  6e 67 20 74 68 65 20 6f  75 74 70 75 74 20 6f 72  |ng the output or|
000004c0  20 6e 6f 74 2e 22 0d 01  90 16 20 f2 57 4f 52 44  | not.".... .WORD|
000004d0  5f 57 52 41 50 28 46 24  2c 4c 25 29 0d 01 9a 07  |_WRAP(F$,L%)....|
000004e0  20 f1 27 0d 01 a4 28 20  46 24 3d 22 50 72 69 6e  | .'...( F$="Prin|
000004f0  74 69 6e 67 20 74 68 65  20 61 6e 61 67 72 61 6d  |ting the anagram|
00000500  73 2c 20 6f 72 20 6e 6f  74 2e 22 0d 01 ae 16 20  |s, or not.".... |
00000510  f2 57 4f 52 44 5f 57 52  41 50 28 46 24 2c 4c 25  |.WORD_WRAP(F$,L%|
00000520  29 0d 01 b8 07 20 f1 27  0d 01 c2 5b 20 46 24 3d  |).... .'...[ F$=|
00000530  22 54 65 73 74 69 6e 67  20 74 68 65 20 70 72 6f  |"Testing the pro|
00000540  67 72 61 6d 20 74 6f 20  73 65 65 20 68 6f 77 20  |gram to see how |
00000550  6c 6f 6e 67 20 69 74 20  74 61 6b 65 73 20 74 6f  |long it takes to|
00000560  20 66 69 6e 64 20 61 20  73 70 65 63 69 66 69 65  | find a specifie|
00000570  64 20 61 6e 61 67 72 61  6d 2c 20 6f 72 20 6e 6f  |d anagram, or no|
00000580  74 2e 22 0d 01 cc 16 20  f2 57 4f 52 44 5f 57 52  |t.".... .WORD_WR|
00000590  41 50 28 46 24 2c 4c 25  29 0d 01 d6 0f 20 f2 5f  |AP(F$,L%).... ._|
000005a0  43 4f 4e 54 49 4e 55 45  0d 01 e0 0b 20 f1 27 27  |CONTINUE.... .''|
000005b0  27 27 27 0d 01 ea b9 20  46 24 3d 22 49 66 20 70  |'''.... F$="If p|
000005c0  72 69 6e 74 69 6e 67 2c  20 6e 6f 74 65 20 74 68  |rinting, note th|
000005d0  61 74 20 69 74 20 69 73  20 6c 69 6b 65 6c 79 20  |at it is likely |
000005e0  74 6f 20 75 73 65 20 61  20 67 72 65 61 74 20 64  |to use a great d|
000005f0  65 61 6c 20 6f 66 20 70  61 70 65 72 20 66 6f 72  |eal of paper for|
00000600  20 61 20 6c 6f 6e 67 20  77 6f 72 64 3b 20 69 6e  | a long word; in|
00000610  20 74 68 65 20 53 79 73  74 65 6d 61 74 69 63 20  | the Systematic |
00000620  6d 6f 64 65 2c 20 73 6f  6d 65 20 69 6e 64 69 63  |mode, some indic|
00000630  61 74 69 6f 6e 20 6f 66  20 74 68 69 73 20 69 73  |ation of this is|
00000640  20 67 69 76 65 6e 20 62  79 20 74 68 65 20 46 61  | given by the Fa|
00000650  63 74 6f 72 69 61 6c 73  20 64 61 74 61 20 74 68  |ctorials data th|
00000660  61 74 20 66 6f 6c 6c 6f  77 73 2e 22 0d 01 f4 16  |at follows."....|
00000670  20 f2 57 4f 52 44 5f 57  52 41 50 28 46 24 2c 4c  | .WORD_WRAP(F$,L|
00000680  25 29 0d 01 fe 07 20 f1  27 0d 02 08 97 20 46 24  |%).... .'.... F$|
00000690  3d 22 49 6e 20 74 68 65  20 52 61 6e 64 6f 6d 20  |="In the Random |
000006a0  6d 6f 64 65 2c 20 69 66  20 73 65 61 72 63 68 69  |mode, if searchi|
000006b0  6e 67 20 66 6f 72 20 61  20 73 70 65 63 69 66 69  |ng for a specifi|
000006c0  65 64 20 61 6e 61 67 72  61 6d 2c 20 69 74 20 6d  |ed anagram, it m|
000006d0  61 79 20 62 65 20 66 6f  75 6e 64 20 69 6e 73 74  |ay be found inst|
000006e0  61 6e 74 6c 79 20 6f 72  20 61 6c 6d 6f 73 74 20  |antly or almost |
000006f0  6e 65 76 65 72 3b 20 69  66 20 6e 6f 74 20 73 65  |never; if not se|
00000700  61 72 63 68 69 6e 67 2c  20 69 74 20 57 49 4c 4c  |arching, it WILL|
00000710  20 72 75 6e 20 66 6f 72  20 65 76 65 72 20 21 22  | run for ever !"|
00000720  0d 02 12 16 20 f2 57 4f  52 44 5f 57 52 41 50 28  |.... .WORD_WRAP(|
00000730  46 24 2c 4c 25 29 0d 02  1c 07 20 f1 27 0d 02 26  |F$,L%).... .'..&|
00000740  2e 20 46 24 3d 22 48 6f  75 73 65 77 69 76 65 73  |. F$="Housewives|
00000750  20 61 6e 64 20 42 61 6e  6b 20 4d 61 6e 61 67 65  | and Bank Manage|
00000760  72 73 20 62 65 77 61 72  65 2e 22 0d 02 30 16 20  |rs beware."..0. |
00000770  f2 57 4f 52 44 5f 57 52  41 50 28 46 24 2c 4c 25  |.WORD_WRAP(F$,L%|
00000780  29 0d 02 3a 0f 20 f2 5f  43 4f 4e 54 49 4e 55 45  |)..:. ._CONTINUE|
00000790  0d 02 44 0d 20 f1 27 27  27 27 27 27 27 0d 02 4e  |..D. .'''''''..N|
000007a0  bf 20 46 24 3d 22 46 6f  72 20 61 20 73 65 72 69  |. F$="For a seri|
000007b0  61 6c 2c 20 72 61 74 68  65 72 20 74 68 61 6e 20  |al, rather than |
000007c0  61 20 70 61 72 61 6c 6c  65 6c 20 70 72 69 6e 74  |a parallel print|
000007d0  65 72 20 64 65 6c 65 74  65 20 74 68 65 20 52 45  |er delete the RE|
000007e0  4d 20 69 6e 20 6c 69 6e  65 20 31 36 37 30 2e 20  |M in line 1670. |
000007f0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
*
00000810  20 20 20 20 20 20 20 20  20 20 20 54 6f 20 73 65  |           To se|
00000820  65 20 74 68 65 20 52 61  6e 64 6f 6d 20 67 65 6e  |e the Random gen|
00000830  65 72 61 74 6f 72 20 61  74 20 77 6f 72 6b 20 64  |erator at work d|
00000840  65 6c 65 74 65 20 74 68  65 20 52 45 4d 20 69 6e  |elete the REM in|
00000850  20 6c 69 6e 65 20 34 30  39 30 2e 22 0d 02 58 16  | line 4090."..X.|
00000860  20 f2 57 4f 52 44 5f 57  52 41 50 28 46 24 2c 4c  | .WORD_WRAP(F$,L|
00000870  25 29 0d 02 62 0f 20 f2  5f 43 4f 4e 54 49 4e 55  |%)..b. ._CONTINU|
00000880  45 0d 02 6c 25 20 f1 8a  31 30 2c 34 29 3b bd 31  |E..l% ..10,4);.1|
00000890  33 31 3b 22 43 72 6f 73  73 77 6f 72 64 20 73 6f  |31;"Crossword so|
000008a0  6c 76 65 72 73 22 0d 02  76 06 20 f1 0d 02 80 ec  |lvers"..v. .....|
000008b0  20 46 24 3d 22 44 6f 20  6e 6f 74 20 65 78 70 65  | F$="Do not expe|
000008c0  63 74 20 74 68 65 20 70  72 6f 67 72 61 6d 20 74  |ct the program t|
000008d0  6f 20 66 69 6e 64 20 75  6e 6b 6e 6f 77 6e 20 61  |o find unknown a|
000008e0  6e 61 67 72 61 6d 73 20  66 6f 72 20 79 6f 75 2e  |nagrams for you.|
000008f0  20 20 20 20 20 20 20 20  20 20 20 20 20 20 42 75  |              Bu|
00000900  74 20 69 74 20 77 69 6c  6c 20 68 65 6c 70 2e 20  |t it will help. |
00000910  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
00000920  20 20 20 43 68 75 72 6e  20 74 68 65 6d 20 6f 75  |   Churn them ou|
00000930  74 20 73 6c 6f 77 6c 79  20 2d 20 6f 72 20 70 72  |t slowly - or pr|
00000940  69 6e 74 20 27 65 6d 2e  20 53 74 75 64 79 20 74  |int 'em. Study t|
00000950  68 65 20 76 61 72 69 6f  75 73 20 63 6f 6d 62 69  |he various combi|
00000960  6e 61 74 69 6f 6e 73 20  6f 66 20 6c 65 74 74 65  |nations of lette|
00000970  72 73 2c 20 61 6e 64 20  69 6e 73 70 69 72 61 74  |rs, and inspirat|
00000980  69 6f 6e 20 77 69 6c 6c  20 73 75 72 65 6c 79 20  |ion will surely |
00000990  66 6f 6c 6c 6f 77 2e 22  0d 02 8a 16 20 f2 57 4f  |follow.".... .WO|
000009a0  52 44 5f 57 52 41 50 28  46 24 2c 4c 25 29 0d 02  |RD_WRAP(F$,L%)..|
000009b0  94 07 20 f1 27 0d 02 9e  0d 20 f1 22 54 72 79 20  |.. .'.... ."Try |
000009c0  2d 22 0d 02 a8 2c 20 f1  22 4f 52 43 48 45 53 54  |-"..., ."ORCHEST|
000009d0  52 41 2f 43 41 52 54 48  4f 52 53 45 2e 20 20 20  |RA/CARTHORSE.   |
000009e0  20 20 20 20 20 20 20 20  46 75 6e 20 21 22 0d 02  |        Fun !"..|
000009f0  b2 0d 20 f1 27 22 6f 72  20 2d 22 0d 02 bc 17 20  |.. .'"or -".... |
00000a00  f1 22 50 4f 53 54 2f 53  54 4f 50 2f 4f 50 54 53  |."POST/STOP/OPTS|
00000a10  2f 22 0d 02 c6 2c 20 f1  22 50 4f 54 53 2f 53 50  |/"..., ."POTS/SP|
00000a20  4f 54 2f 54 4f 50 53 2e  20 20 20 20 20 20 20 20  |OT/TOPS.        |
00000a30  20 20 20 20 20 43 68 65  61 70 65 72 2e 22 0d 02  |     Cheaper."..|
00000a40  d0 0f 20 f2 5f 43 4f 4e  54 49 4e 55 45 0d 02 da  |.. ._CONTINUE...|
00000a50  11 20 f2 5f 46 41 43 54  4f 52 49 41 4c 53 0d 02  |. ._FACTORIALS..|
00000a60  e4 15 20 ef 32 33 3b 32  39 31 39 34 3b 30 3b 30  |.. .23;29194;0;0|
00000a70  3b 30 3b 0d 02 ee 58 20  41 4e 24 3d 22 22 3a 57  |;0;...X AN$="":W|
00000a80  4f 52 44 24 3d 22 22 3a  46 25 3d 31 3a 47 24 3d  |ORD$="":F%=1:G$=|
00000a90  22 22 3a 50 24 3d 22 22  3a 66 69 6e 64 24 3d 22  |"":P$="":find$="|
00000aa0  22 3a 61 6e 73 24 3d 22  22 3a 70 61 67 65 64 25  |":ans$="":paged%|
00000ab0  3d 30 3a 72 75 6e 25 3d  30 3a 74 69 6d 65 64 25  |=0:run%=0:timed%|
00000ac0  3d 30 3a 70 72 69 6e 74  25 3d 30 0d 02 f8 0e 20  |=0:print%=0.... |
00000ad0  f2 5f 53 59 53 52 41 4e  44 0d 03 02 0c 20 f2 5f  |._SYSRAND.... ._|
00000ae0  45 4e 54 45 52 0d 03 0c  0d 20 f2 5f 4f 55 54 50  |ENTER.... ._OUTP|
00000af0  55 54 0d 03 16 0b 20 f2  5f 54 45 53 54 0d 03 20  |UT.... ._TEST.. |
00000b00  0c 20 f2 5f 50 52 49 4e  54 0d 03 2a 06 20 f1 0d  |. ._PRINT..*. ..|
00000b10  03 34 31 20 e7 20 74 69  6d 65 64 25 20 e8 22 45  |.41 . timed% ."E|
00000b20  6e 74 65 72 20 79 6f 75  72 20 63 68 6f 73 65 6e  |nter your chosen|
00000b30  20 61 6e 61 67 72 61 6d  20 22 3b 66 69 6e 64 24  | anagram ";find$|
00000b40  0d 03 3e 0f 20 f2 5f 43  4f 4e 54 49 4e 55 45 0d  |..>. ._CONTINUE.|
00000b50  03 48 17 20 ef 31 32 2c  32 33 3b 38 32 30 32 3b  |.H. .12,23;8202;|
00000b60  30 3b 30 3b 30 3b 0d 03  52 21 20 e7 20 72 75 6e  |0;0;0;..R! . run|
00000b70  25 3d 30 20 f2 5f 53 49  4e 47 4c 45 3a f2 5f 43  |%=0 ._SINGLE:._C|
00000b80  4f 4e 54 49 4e 55 45 0d  03 5c 13 20 77 6f 72 64  |ONTINUE..\. word|
00000b90  24 3d 57 4f 52 44 24 3a  20 db 0d 03 66 10 20 e7  |$=WORD$: ...f. .|
00000ba0  20 70 72 69 6e 74 25 20  ef 32 0d 03 70 23 20 e7  | print% .2..p# .|
00000bb0  20 70 72 69 6e 74 25 20  80 20 72 75 6e 25 20 ef  | print% . run% .|
00000bc0  31 2c 32 37 2c 31 2c 37  38 2c 31 2c 36 0d 03 7a  |1,27,1,78,1,6..z|
00000bd0  25 20 f1 8a 31 34 2c 31  29 22 41 6e 61 67 72 61  |% ..14,1)"Anagra|
00000be0  6d 73 20 6f 66 20 22 3b  bd 31 33 31 3b 57 4f 52  |ms of ";.131;WOR|
00000bf0  44 24 0d 03 84 06 20 f1  0d 03 8e 08 20 d1 3d 30  |D$.... ..... .=0|
00000c00  0d 03 98 22 20 e7 20 73  79 73 74 25 20 8c 20 f2  |..." . syst% . .|
00000c10  5f 53 79 73 74 65 6d 20  8b 20 f2 5f 52 61 6e 64  |_System . ._Rand|
00000c20  6f 6d 0d 03 a2 05 20 0d  03 ac 0e 20 ef 33 2c 31  |om.... .... .3,1|
00000c30  35 3a 20 f1 27 0d 03 b6  0c 20 f2 5f 41 47 41 49  |5: .'.... ._AGAI|
00000c40  4e 0d 03 c0 06 20 db 0d  03 ca 20 20 f2 5f 54 49  |N.... ....  ._TI|
00000c50  54 4c 45 28 22 42 20 59  20 45 20 20 42 20 59 20  |TLE("B Y E  B Y |
00000c60  45 22 2c 31 33 31 29 0d  03 d4 15 20 ef 32 33 3b  |E",131).... .23;|
00000c70  32 39 31 39 34 3b 30 3b  30 3b 30 3b 0d 03 de 06  |29194;0;0;0;....|
00000c80  20 e0 0d 03 e8 0e 20 dd  f2 5f 53 79 73 74 65 6d  | ..... .._System|
00000c90  0d 03 f2 07 20 f1 3b 0d  03 fc 3a 20 63 24 3d 22  |.... .;...: c$="|
00000ca0  22 3a 62 24 3d 22 22 3a  61 24 3d 22 22 3a 41 24  |":b$="":a$="":A$|
00000cb0  3d 22 22 3a 42 24 3d 22  22 3a 43 24 3d 22 22 3a  |="":B$="":C$="":|
00000cc0  44 24 3d 22 22 3a 45 24  3d 22 22 3a 46 24 3d 22  |D$="":E$="":F$="|
00000cd0  22 0d 04 06 14 20 46 24  3d c1 57 4f 52 44 24 2c  |".... F$=.WORD$,|
00000ce0  6c 25 2c 31 29 0d 04 10  24 20 45 24 3d c1 57 4f  |l%,1)...$ E$=.WO|
00000cf0  52 44 24 2c 6c 25 2d 31  2c 31 29 3a e7 20 6c 25  |RD$,l%-1,1):. l%|
00000d00  3d 32 20 8c 20 8d 64 76  44 0d 04 1a 24 20 44 24  |=2 . .dvD...$ D$|
00000d10  3d c1 57 4f 52 44 24 2c  6c 25 2d 32 2c 31 29 3a  |=.WORD$,l%-2,1):|
00000d20  e7 20 6c 25 3d 33 20 8c  20 8d 64 62 44 0d 04 24  |. l%=3 . .dbD..$|
00000d30  24 20 43 24 3d c1 57 4f  52 44 24 2c 6c 25 2d 33  |$ C$=.WORD$,l%-3|
00000d40  2c 31 29 3a e7 20 6c 25  3d 34 20 8c 20 8d 64 4e  |,1):. l%=4 . .dN|
00000d50  44 0d 04 2e 24 20 42 24  3d c1 57 4f 52 44 24 2c  |D...$ B$=.WORD$,|
00000d60  6c 25 2d 34 2c 31 29 3a  e7 20 6c 25 3d 35 20 8c  |l%-4,1):. l%=5 .|
00000d70  20 8d 74 7a 44 0d 04 38  24 20 41 24 3d c1 57 4f  | .tzD..8$ A$=.WO|
00000d80  52 44 24 2c 6c 25 2d 35  2c 31 29 3a e7 20 6c 25  |RD$,l%-5,1):. l%|
00000d90  3d 36 20 8c 20 8d 74 66  44 0d 04 42 24 20 61 24  |=6 . .tfD..B$ a$|
00000da0  3d c1 57 4f 52 44 24 2c  6c 25 2d 36 2c 31 29 3a  |=.WORD$,l%-6,1):|
00000db0  e7 20 6c 25 3d 37 20 8c  20 8d 74 52 44 0d 04 4c  |. l%=7 . .tRD..L|
00000dc0  24 20 62 24 3d c1 57 4f  52 44 24 2c 6c 25 2d 37  |$ b$=.WORD$,l%-7|
00000dd0  2c 31 29 3a e7 20 6c 25  3d 38 20 8c 20 8d 44 7e  |,1):. l%=8 . .D~|
00000de0  44 0d 04 56 16 20 63 24  3d c1 57 4f 52 44 24 2c  |D..V. c$=.WORD$,|
00000df0  6c 25 2d 38 2c 31 29 0d  04 60 0e e3 20 47 25 3d  |l%-8,1)..`.. G%=|
00000e00  31 20 b8 20 39 0d 04 6a  0a 41 4e 24 3d 22 22 0d  |1 . 9..j.AN$="".|
00000e10  04 74 0e 41 4e 24 3d 41  4e 24 2b 63 24 0d 04 7e  |.t.AN$=AN$+c$..~|
00000e20  0e e3 20 48 25 3d 31 20  b8 20 38 0d 04 88 0e 41  |.. H%=1 . 8....A|
00000e30  4e 24 3d 41 4e 24 2b 62  24 0d 04 92 0f 20 e3 20  |N$=AN$+b$.... . |
00000e40  49 25 3d 31 20 b8 20 37  0d 04 9c 0f 20 41 4e 24  |I%=1 . 7.... AN$|
00000e50  3d 41 4e 24 2b 61 24 0d  04 a6 0f 20 e3 20 4a 25  |=AN$+a$.... . J%|
00000e60  3d 31 20 b8 20 36 0d 04  b0 0f 20 41 4e 24 3d 41  |=1 . 6.... AN$=A|
00000e70  4e 24 2b 41 24 0d 04 ba  0f 20 e3 20 4b 25 3d 31  |N$+A$.... . K%=1|
00000e80  20 b8 20 35 0d 04 c4 0f  20 41 4e 24 3d 41 4e 24  | . 5.... AN$=AN$|
00000e90  2b 42 24 0d 04 ce 0f 20  e3 20 4c 25 3d 31 20 b8  |+B$.... . L%=1 .|
00000ea0  20 34 0d 04 d8 0f 20 41  4e 24 3d 41 4e 24 2b 43  | 4.... AN$=AN$+C|
00000eb0  24 0d 04 e2 0f 20 e3 20  4d 25 3d 31 20 b8 20 33  |$.... . M%=1 . 3|
00000ec0  0d 04 ec 0f 20 41 4e 24  3d 41 4e 24 2b 44 24 0d  |.... AN$=AN$+D$.|
00000ed0  04 f6 0e e3 20 4e 25 3d  31 20 b8 20 32 0d 05 00  |.... N%=1 . 2...|
00000ee0  0e 41 4e 24 3d 41 4e 24  2b 45 24 0d 05 0a 0e 41  |.AN$=AN$+E$....A|
00000ef0  4e 24 3d 41 4e 24 2b 46  24 0d 05 14 1f 20 f1 8a  |N$=AN$+F$.... ..|
00000f00  31 35 29 46 25 3b 22 20  20 22 3b 41 4e 24 20 3a  |15)F%;"  ";AN$ :|
00000f10  20 46 25 3d 46 25 2b 31  0d 05 1e 0b 20 f2 5f 66  | F%=F%+1.... ._f|
00000f20  69 6e 64 0d 05 28 14 20  e7 20 72 75 6e 25 3d 30  |ind..(. . run%=0|
00000f30  20 f2 5f 4e 45 58 54 0d  05 32 26 20 e7 20 72 75  | ._NEXT..2& . ru|
00000f40  6e 25 20 80 20 70 61 67  65 64 25 20 80 20 46 25  |n% . paged% . F%|
00000f50  83 32 31 3d 30 20 f2 5f  53 48 49 46 54 0d 05 3c  |.21=0 ._SHIFT..<|
00000f60  19 5a 24 3d 45 24 20 3a  20 45 24 3d 46 24 20 3a  |.Z$=E$ : E$=F$ :|
00000f70  20 46 24 3d 5a 24 0d 05  46 1d 20 41 4e 24 3d 63  | F$=Z$..F. AN$=c|
00000f80  24 2b 62 24 2b 61 24 2b  41 24 2b 42 24 2b 43 24  |$+b$+a$+A$+B$+C$|
00000f90  2b 44 24 0d 05 50 09 20  ed 20 4e 25 0d 05 5a 12  |+D$..P. . N%..Z.|
00000fa0  20 e7 20 6c 25 3d 32 20  e5 20 8d 44 68 46 0d 05  | . l%=2 . .DhF..|
00000fb0  64 22 20 5a 24 3d 44 24  20 3a 20 44 24 3d 45 24  |d" Z$=D$ : D$=E$|
00000fc0  20 3a 20 45 24 3d 46 24  20 3a 20 46 24 3d 5a 24  | : E$=F$ : F$=Z$|
00000fd0  0d 05 6e 1a 20 41 4e 24  3d 63 24 2b 62 24 2b 61  |..n. AN$=c$+b$+a|
00000fe0  24 2b 41 24 2b 42 24 2b  43 24 0d 05 78 09 20 ed  |$+A$+B$+C$..x. .|
00000ff0  20 4d 25 0d 05 82 12 20  e7 20 6c 25 3d 33 20 e5  | M%.... . l%=3 .|
00001000  20 8d 44 68 46 0d 05 8c  2a 20 5a 24 3d 43 24 20  | .DhF...* Z$=C$ |
00001010  3a 20 43 24 3d 44 24 20  3a 20 44 24 3d 45 24 20  |: C$=D$ : D$=E$ |
00001020  3a 20 45 24 3d 46 24 20  3a 20 46 24 3d 5a 24 0d  |: E$=F$ : F$=Z$.|
00001030  05 96 17 20 41 4e 24 3d  63 24 2b 62 24 2b 61 24  |... AN$=c$+b$+a$|
00001040  2b 41 24 2b 42 24 0d 05  a0 09 20 ed 20 4c 25 0d  |+A$+B$.... . L%.|
00001050  05 aa 12 20 e7 20 6c 25  3d 34 20 e5 20 8d 44 68  |... . l%=4 . .Dh|
00001060  46 0d 05 b4 32 20 5a 24  3d 42 24 20 3a 20 42 24  |F...2 Z$=B$ : B$|
00001070  3d 43 24 20 3a 20 43 24  3d 44 24 20 3a 20 44 24  |=C$ : C$=D$ : D$|
00001080  3d 45 24 20 3a 20 45 24  3d 46 24 20 3a 20 46 24  |=E$ : E$=F$ : F$|
00001090  3d 5a 24 0d 05 be 14 20  41 4e 24 3d 63 24 2b 62  |=Z$.... AN$=c$+b|
000010a0  24 2b 61 24 2b 41 24 0d  05 c8 09 20 ed 20 4b 25  |$+a$+A$.... . K%|
000010b0  0d 05 d2 12 20 e7 20 6c  25 3d 35 20 e5 20 8d 44  |.... . l%=5 . .D|
000010c0  68 46 0d 05 dc 3a 20 5a  24 3d 41 24 20 3a 20 41  |hF...: Z$=A$ : A|
000010d0  24 3d 42 24 20 3a 20 42  24 3d 43 24 20 3a 20 43  |$=B$ : B$=C$ : C|
000010e0  24 3d 44 24 20 3a 20 44  24 3d 45 24 20 3a 20 45  |$=D$ : D$=E$ : E|
000010f0  24 3d 46 24 20 3a 20 46  24 3d 5a 24 0d 05 e6 11  |$=F$ : F$=Z$....|
00001100  20 41 4e 24 3d 63 24 2b  62 24 2b 61 24 0d 05 f0  | AN$=c$+b$+a$...|
00001110  09 20 ed 20 4a 25 0d 05  fa 12 20 e7 20 6c 25 3d  |. . J%.... . l%=|
00001120  36 20 e5 20 8d 44 68 46  0d 06 04 42 20 5a 24 3d  |6 . .DhF...B Z$=|
00001130  61 24 20 3a 20 61 24 3d  41 24 20 3a 20 41 24 3d  |a$ : a$=A$ : A$=|
00001140  42 24 20 3a 20 42 24 3d  43 24 20 3a 20 43 24 3d  |B$ : B$=C$ : C$=|
00001150  44 24 20 3a 20 44 24 3d  45 24 20 3a 20 45 24 3d  |D$ : D$=E$ : E$=|
00001160  46 24 20 3a 20 46 24 3d  5a 24 0d 06 0e 0e 20 41  |F$ : F$=Z$.... A|
00001170  4e 24 3d 63 24 2b 62 24  0d 06 18 09 20 ed 20 49  |N$=c$+b$.... . I|
00001180  25 0d 06 22 11 e7 20 6c  25 3d 37 20 e5 20 8d 44  |%..".. l%=7 . .D|
00001190  68 46 0d 06 2c 45 5a 24  3d 62 24 3a 62 24 3d 61  |hF..,EZ$=b$:b$=a|
000011a0  24 3a 61 24 3d 41 24 20  3a 20 41 24 3d 42 24 20  |$:a$=A$ : A$=B$ |
000011b0  3a 20 42 24 3d 43 24 20  3a 20 43 24 3d 44 24 20  |: B$=C$ : C$=D$ |
000011c0  3a 20 44 24 3d 45 24 20  3a 20 45 24 3d 46 24 20  |: D$=E$ : E$=F$ |
000011d0  3a 20 46 24 3d 5a 24 0d  06 36 0a 41 4e 24 3d 63  |: F$=Z$..6.AN$=c|
000011e0  24 0d 06 40 08 ed 20 48  25 0d 06 4a 11 e7 20 6c  |$..@.. H%..J.. l|
000011f0  25 3d 38 20 e5 20 8d 44  68 46 0d 06 54 4b 5a 24  |%=8 . .DhF..TKZ$|
00001200  3d 63 24 3a 63 24 3d 62  24 3a 62 24 3d 61 24 3a  |=c$:c$=b$:b$=a$:|
00001210  61 24 3d 41 24 20 3a 20  41 24 3d 42 24 20 3a 20  |a$=A$ : A$=B$ : |
00001220  42 24 3d 43 24 20 3a 20  43 24 3d 44 24 20 3a 20  |B$=C$ : C$=D$ : |
00001230  44 24 3d 45 24 20 3a 20  45 24 3d 46 24 20 3a 20  |D$=E$ : E$=F$ : |
00001240  46 24 3d 5a 24 0d 06 5e  08 ed 20 47 25 0d 06 68  |F$=Z$..^.. G%..h|
00001250  27 20 e7 20 74 69 6d 65  64 25 3d 30 20 f1 27 22  |' . timed%=0 .'"|
00001260  54 68 61 74 27 73 20 74  68 65 20 6c 6f 74 2e 22  |That's the lot."|
00001270  27 3a ef 37 0d 06 72 06  20 e1 0d 06 7c 0d 20 dd  |':.7..r. ...|. .|
00001280  f2 5f 50 52 49 4e 54 0d  06 86 0d 20 f4 20 2a 46  |._PRINT.... . *F|
00001290  58 35 2c 32 0d 06 90 06  20 f5 0d 06 9a 24 20 f1  |X5,2.... ....$ .|
000012a0  27 22 44 6f 20 79 6f 75  20 77 69 73 68 20 74 6f  |'"Do you wish to|
000012b0  22 3b bd 31 32 39 3b 22  70 72 69 6e 74 22 0d 06  |";.129;"print"..|
000012c0  a4 1d 20 f1 22 74 68 65  20 61 6e 61 67 72 61 6d  |.. ."the anagram|
000012d0  73 20 3f 20 28 59 2f 4e  29 22 3b 0d 06 ae 09 20  |s ? (Y/N)";.... |
000012e0  47 24 3d be 0d 06 b8 28  20 fd 20 47 24 3d 22 59  |G$=....( . G$="Y|
000012f0  22 20 84 20 47 24 3d 22  79 22 20 84 20 47 24 3d  |" . G$="y" . G$=|
00001300  22 4e 22 20 84 20 47 24  3d 22 6e 22 0d 06 c2 12  |"N" . G$="n"....|
00001310  20 f1 8a 33 34 29 3b bd  31 32 39 3b 47 24 0d 06  | ..34);.129;G$..|
00001320  cc 18 20 e7 20 47 24 3d  22 4e 22 20 84 20 47 24  |.. . G$="N" . G$|
00001330  3d 22 6e 22 20 e1 0d 06  d6 06 20 f5 0d 06 e0 06  |="n" ..... .....|
00001340  20 f1 0d 06 ea 27 20 f1  bd 31 32 39 3b 22 41 72  | ....' ..129;"Ar|
00001350  65 20 79 6f 75 20 53 55  52 45 20 3f 20 20 20 20  |e you SURE ?    |
00001360  20 20 28 59 2f 4e 29 22  3b 0d 06 f4 09 20 47 24  |  (Y/N)";.... G$|
00001370  3d be 0d 06 fe 28 20 fd  20 47 24 3d 22 59 22 20  |=....( . G$="Y" |
00001380  84 20 47 24 3d 22 79 22  20 84 20 47 24 3d 22 4e  |. G$="y" . G$="N|
00001390  22 20 84 20 47 24 3d 22  6e 22 0d 07 08 12 20 f1  |" . G$="n".... .|
000013a0  8a 33 34 29 3b bd 31 32  39 3b 47 24 0d 07 12 20  |.34);.129;G$... |
000013b0  20 e7 20 47 24 3d 22 59  22 20 84 20 47 24 3d 22  | . G$="Y" . G$="|
000013c0  79 22 20 70 72 69 6e 74  25 3d 2d 31 0d 07 1c 22  |y" print%=-1..."|
000013d0  20 e7 20 47 24 3d 22 4e  22 20 84 20 47 24 3d 22  | . G$="N" . G$="|
000013e0  6e 22 20 70 72 69 6e 74  25 3d 30 3a 20 e1 0d 07  |n" print%=0: ...|
000013f0  26 06 20 f5 0d 07 30 26  20 f1 27 22 50 72 65 73  |&. ...0& .'"Pres|
00001400  73 20 27 50 27 20 77 68  65 6e 20 70 72 69 6e 74  |s 'P' when print|
00001410  65 72 20 72 65 61 64 79  22 3b 0d 07 3a 09 20 47  |er ready";..:. G|
00001420  24 3d be 0d 07 44 16 20  fd 20 47 24 3d 22 50 22  |$=...D. . G$="P"|
00001430  20 84 20 47 24 3d 22 70  22 0d 07 4e 0c 20 f1 8a  | . G$="p"..N. ..|
00001440  33 35 29 47 24 0d 07 58  1e 20 e7 20 72 75 6e 25  |35)G$..X. . run%|
00001450  20 ef 32 2c 31 2c 32 37  2c 31 2c 37 38 2c 31 2c  | .2,1,27,1,78,1,|
00001460  36 2c 33 0d 07 62 06 20  e1 0d 07 6c 0e 20 dd f2  |6,3..b. ...l. ..|
00001470  5f 4f 55 54 50 55 54 0d  07 76 06 20 f5 0d 07 80  |_OUTPUT..v. ....|
00001480  2c 20 f1 27 22 44 6f 20  79 6f 75 20 77 61 6e 74  |, .'"Do you want|
00001490  20 61 22 3b bd 31 33 31  3b 22 72 75 6e 6e 69 6e  | a";.131;"runnin|
000014a0  67 20 6f 75 74 70 75 74  22 0d 07 8a 25 20 f1 22  |g output"...% ."|
000014b0  6f 66 20 74 68 65 20 61  6e 61 67 72 61 6d 73 20  |of the anagrams |
000014c0  3f 20 20 20 20 20 20 28  59 2f 4e 29 22 3b 0d 07  |?      (Y/N)";..|
000014d0  94 09 20 47 24 3d be 0d  07 9e 28 20 fd 20 47 24  |.. G$=....( . G$|
000014e0  3d 22 59 22 20 84 20 47  24 3d 22 79 22 20 84 20  |="Y" . G$="y" . |
000014f0  47 24 3d 22 4e 22 20 84  20 47 24 3d 22 6e 22 0d  |G$="N" . G$="n".|
00001500  07 a8 12 20 f1 8a 33 34  29 3b bd 31 33 31 3b 47  |... ..34);.131;G|
00001510  24 0d 07 b2 35 20 e7 20  47 24 3d 22 59 22 20 84  |$...5 . G$="Y" .|
00001520  20 47 24 3d 22 79 22 20  8c 20 72 75 6e 25 3d 2d  | G$="y" . run%=-|
00001530  31 3a 20 f2 5f 50 41 47  45 3a 20 e1 3a 20 8b 20  |1: ._PAGE: .: . |
00001540  72 75 6e 25 3d 30 0d 07  bc 06 20 e1 0d 07 c6 0c  |run%=0.... .....|
00001550  20 dd f2 5f 54 45 53 54  0d 07 d0 06 20 f5 0d 07  | .._TEST.... ...|
00001560  da 37 20 f1 27 22 44 6f  20 79 6f 75 20 77 69 73  |.7 .'"Do you wis|
00001570  68 20 74 6f 22 3b bd 31  33 34 3b 22 74 65 73 74  |h to";.134;"test|
00001580  22 3b bd 31 33 35 3b 22  74 68 65 20 70 72 6f 67  |";.135;"the prog|
00001590  72 61 6d 2c 22 0d 07 e4  28 20 f1 22 74 6f 20 73  |ram,"...( ."to s|
000015a0  65 65 20 68 6f 77 20 6c  6f 6e 67 20 69 74 20 74  |ee how long it t|
000015b0  61 6b 65 73 20 74 6f 20  66 69 6e 64 22 0d 07 ee  |akes to find"...|
000015c0  29 20 f1 22 6f 6e 65 20  70 61 72 74 69 63 75 6c  |) ."one particul|
000015d0  61 72 20 61 6e 61 67 72  61 6d 20 3f 20 20 20 28  |ar anagram ?   (|
000015e0  59 2f 4e 29 22 3b 0d 07  f8 09 20 47 24 3d be 0d  |Y/N)";.... G$=..|
000015f0  08 02 28 20 fd 20 47 24  3d 22 59 22 20 84 20 47  |..( . G$="Y" . G|
00001600  24 3d 22 79 22 20 84 20  47 24 3d 22 4e 22 20 84  |$="y" . G$="N" .|
00001610  20 47 24 3d 22 6e 22 0d  08 0c 12 20 f1 8a 33 34  | G$="n".... ..34|
00001620  29 3b bd 31 33 34 3b 47  24 0d 08 16 2d 20 e7 20  |);.134;G$...- . |
00001630  47 24 3d 22 59 22 20 84  20 47 24 3d 22 79 22 20  |G$="Y" . G$="y" |
00001640  8c 20 74 69 6d 65 64 25  3d 2d 31 20 8b 20 74 69  |. timed%=-1 . ti|
00001650  6d 65 64 25 3d 30 0d 08  20 06 20 e1 0d 08 2a 0c  |med%=0.. . ...*.|
00001660  20 dd f2 5f 4e 45 58 54  0d 08 34 06 20 f5 0d 08  | .._NEXT..4. ...|
00001670  3e 09 20 47 24 3d be 0d  08 48 1f 20 fd 20 47 24  |>. G$=...H. . G$|
00001680  3d 22 20 22 20 84 20 47  24 3d 22 57 22 20 84 20  |=" " . G$="W" . |
00001690  47 24 3d 22 77 22 0d 08  52 31 20 e7 20 47 24 3d  |G$="w"..R1 . G$=|
000016a0  22 57 22 20 84 20 47 24  3d 22 77 22 20 8c 20 f1  |"W" . G$="w" . .|
000016b0  3a 20 f1 8a 32 37 29 77  6f 72 64 24 3a 20 f1 3a  |: ..27)word$: .:|
000016c0  20 f2 5f 4e 45 58 54 0d  08 5c 06 20 e1 0d 08 66  | ._NEXT..\. ...f|
000016d0  0d 20 dd f2 5f 45 4e 54  45 52 0d 08 70 06 20 f1  |. .._ENTER..p. .|
000016e0  0d 08 7a 15 20 e7 20 73  79 73 74 25 3d 30 20 e5  |..z. . syst%=0 .|
000016f0  20 8d 74 62 48 0d 08 84  05 f5 0d 08 8e 27 20 f1  | .tbH........' .|
00001700  22 45 6e 74 65 72 20 77  6f 72 64 20 20 20 20 20  |"Enter word     |
00001710  20 20 20 20 20 20 20 22  3b 3a e8 20 57 4f 52 44  |       ";:. WORD|
00001720  24 0d 08 98 19 fd 20 a9  28 57 4f 52 44 24 29 3c  |$..... .(WORD$)<|
00001730  31 30 3a 20 e5 20 8d 74  6c 48 0d 08 a2 27 20 f1  |10: . .tlH...' .|
00001740  22 45 6e 74 65 72 20 77  6f 72 64 20 20 20 20 20  |"Enter word     |
00001750  20 20 20 20 20 20 20 22  3b 3a e8 20 57 4f 52 44  |       ";:. WORD|
00001760  24 0d 08 ac 10 20 6c 25  3d a9 28 57 4f 52 44 24  |$.... l%=.(WORD$|
00001770  29 0d 08 b6 05 e1 0d 08  c0 0e 20 dd f2 5f 53 49  |)......... .._SI|
00001780  4e 47 4c 45 0d 08 ca 07  20 f1 27 0d 08 d4 2e 20  |NGLE.... .'.... |
00001790  f1 8a 33 2c 31 31 29 22  50 72 65 73 73 20 53 50  |..3,11)"Press SP|
000017a0  41 43 45 20 66 6f 72 20  74 68 65 20 6e 65 78 74  |ACE for the next|
000017b0  20 61 6e 61 67 72 61 6d  22 0d 08 de 2e 20 f1 8a  | anagram".... ..|
000017c0  33 2c 31 33 29 22 50 72  65 73 73 20 27 57 27 20  |3,13)"Press 'W' |
000017d0  66 6f 72 20 74 68 65 20  6f 72 69 67 69 6e 61 6c  |for the original|
000017e0  20 77 6f 72 64 2e 22 0d  08 e8 06 20 e1 0d 08 f2  | word.".... ....|
000017f0  0c 20 dd f2 5f 50 41 47  45 0d 08 fc 06 20 f5 0d  |. .._PAGE.... ..|
00001800  09 06 23 20 f1 27 22 44  6f 20 79 6f 75 20 77 61  |..# .'"Do you wa|
00001810  6e 74 20 74 68 65 20 63  6f 6e 74 69 6e 75 6f 75  |nt the continuou|
00001820  73 22 0d 09 10 31 20 f1  22 6c 69 73 74 20 74 6f  |s"...1 ."list to|
00001830  20 62 65 22 3b bd 31 33  30 3b 22 70 61 67 65 64  | be";.130;"paged|
00001840  22 3b bd 31 33 35 3b 22  3f 20 20 20 28 59 2f 4e  |";.135;"?   (Y/N|
00001850  29 22 3b 0d 09 1a 09 20  47 24 3d be 0d 09 24 28  |)";.... G$=...$(|
00001860  20 fd 20 47 24 3d 22 59  22 20 84 20 47 24 3d 22  | . G$="Y" . G$="|
00001870  79 22 20 84 20 47 24 3d  22 4e 22 20 84 20 47 24  |y" . G$="N" . G$|
00001880  3d 22 6e 22 0d 09 2e 12  20 f1 8a 33 34 29 3b bd  |="n".... ..34);.|
00001890  31 33 30 3b 47 24 0d 09  38 36 20 e7 20 47 24 3d  |130;G$..86 . G$=|
000018a0  22 59 22 20 84 20 47 24  3d 22 79 22 20 8c 20 ef  |"Y" . G$="y" . .|
000018b0  31 34 3a 20 70 61 67 65  64 25 3d 2d 31 3a 20 e1  |14: paged%=-1: .|
000018c0  3a 20 8b 20 70 61 67 65  64 25 3d 30 0d 09 42 06  |: . paged%=0..B.|
000018d0  20 e1 0d 09 4c 0d 20 dd  f2 5f 53 48 49 46 54 0d  | ...L. .._SHIFT.|
000018e0  09 56 13 20 f1 22 50 72  65 73 73 20 53 48 49 46  |.V. ."Press SHIF|
000018f0  54 22 0d 09 60 13 20 f1  22 74 6f 20 63 6f 6e 74  |T"..`. ."to cont|
00001900  69 6e 75 65 22 0d 09 6a  06 20 e1 0d 09 74 17 20  |inue"..j. ...t. |
00001910  dd f2 57 4f 52 44 5f 57  52 41 50 28 50 24 2c 4c  |..WORD_WRAP(P$,L|
00001920  25 29 0d 09 7e 15 20 ea  20 77 6f 72 64 24 2c 20  |%)..~. . word$, |
00001930  49 2c 20 64 6f 6e 65 0d  09 88 0b 20 64 6f 6e 65  |I, done.... done|
00001940  3d 30 0d 09 92 06 20 f5  0d 09 9c 11 20 49 20 3d  |=0.... ..... I =|
00001950  20 a7 50 24 2c 22 20 22  29 0d 09 a6 13 20 77 6f  | .P$," ").... wo|
00001960  72 64 24 20 3d 20 c0 50  24 2c 49 29 0d 09 b0 14  |rd$ = .P$,I)....|
00001970  20 50 24 3d 20 c2 50 24  2c a9 20 50 24 2d 49 29  | P$= .P$,. P$-I)|
00001980  0d 09 ba 15 20 e7 20 50  24 3d 20 22 22 20 64 6f  |.... . P$= "" do|
00001990  6e 65 3d 2d 31 0d 09 c4  1c 20 e7 20 49 3d 30 20  |ne=-1.... . I=0 |
000019a0  77 6f 72 64 24 3d 50 24  3a 20 64 6f 6e 65 3d 2d  |word$=P$: done=-|
000019b0  31 0d 09 ce 15 20 e7 20  a9 20 77 6f 72 64 24 3e  |1.... . . word$>|
000019c0  4c 25 2d 9c 20 f1 0d 09  d8 0d 20 f1 20 77 6f 72  |L%-. ..... . wor|
000019d0  64 24 3b 0d 09 e2 0b 20  fd 20 64 6f 6e 65 0d 09  |d$;.... . done..|
000019e0  ec 06 20 e1 0d 09 f6 10  20 dd f2 5f 43 4f 4e 54  |.. ..... .._CONT|
000019f0  49 4e 55 45 0d 0a 00 06  20 f5 0d 0a 0a 2e 20 f1  |INUE.... ..... .|
00001a00  8a 37 2c 32 34 29 3b bd  28 31 33 30 29 3b 22 50  |.7,24);.(130);"P|
00001a10  72 65 73 73 20 53 50 41  43 45 20 74 6f 20 63 6f  |ress SPACE to co|
00001a20  6e 74 69 6e 75 65 22 3b  0d 0a 14 0c 20 fd 20 be  |ntinue";.... . .|
00001a30  3d 22 20 22 0d 0a 1e 05  db 0d 0a 28 05 e1 0d 0a  |=" ".......(....|
00001a40  32 14 20 dd f2 5f 54 49  54 4c 45 28 54 24 2c 59  |2. .._TITLE(T$,Y|
00001a50  25 29 0d 0a 3c 17 20 ef  31 32 2c 32 33 3b 38 32  |%)..<. .12,23;82|
00001a60  30 32 3b 30 3b 30 3b 30  3b 0d 0a 46 09 20 ea 20  |02;0;0;0;..F. . |
00001a70  51 25 0d 0a 50 16 20 51  25 20 3d 20 31 38 2d 28  |Q%..P. Q% = 18-(|
00001a80  a9 28 54 24 29 2f 32 29  0d 0a 5a 2c 20 e3 20 49  |.(T$)/2)..Z, . I|
00001a90  25 3d 31 31 20 b8 20 31  32 3a f1 8a 51 25 2c 49  |%=11 . 12:..Q%,I|
00001aa0  25 29 3b bd 28 59 25 29  3b bd 28 31 34 31 29 3b  |%);.(Y%);.(141);|
00001ab0  54 24 3a ed 0d 0a 64 0d  20 49 3d a6 28 34 30 30  |T$:...d. I=.(400|
00001ac0  29 0d 0a 6e 06 20 db 0d  0a 78 06 20 e1 0d 0a 82  |)..n. ...x. ....|
00001ad0  12 20 dd f2 5f 46 41 43  54 4f 52 49 41 4c 53 0d  |. .._FACTORIALS.|
00001ae0  0a 8c 06 20 db 0d 0a 96  5a 20 f1 27 22 54 68 65  |... ....Z .'"The|
00001af0  20 6e 75 6d 62 65 72 20  6f 66 20 70 65 72 6d 75  | number of permu|
00001b00  74 61 74 69 6f 6e 73 20  6f 66 20 61 20 77 6f 72  |tations of a wor|
00001b10  64 20 69 73 20 74 68 65  20 66 61 63 74 6f 72 69  |d is the factori|
00001b20  61 6c 20 6f 66 20 69 74  73 20 6e 75 6d 62 65 72  |al of its number|
00001b30  20 6f 66 20 6c 65 74 74  65 72 73 20 2d 22 3b 0d  | of letters -";.|
00001b40  0a a0 48 20 f1 22 61 20  74 68 72 65 65 2d 6c 65  |..H ."a three-le|
00001b50  74 74 65 72 20 77 6f 72  64 20 68 61 73 20 33 78  |tter word has 3x|
00001b60  32 78 31 20 3d 20 36 20  20 20 20 20 20 20 70 65  |2x1 = 6       pe|
00001b70  72 6d 75 74 61 74 69 6f  6e 73 2c 20 65 74 63 2e  |rmutations, etc.|
00001b80  20 54 68 75 73 3a 22 0d  0a aa 18 20 f1 8a 32 37  | Thus:".... ..27|
00001b90  29 22 41 70 70 72 6f 78  20 74 69 6d 65 2c 22 0d  |)"Approx time,".|
00001ba0  0a b4 17 20 f1 8a 32 37  29 22 20 53 79 73 74 65  |... ..27)" Syste|
00001bb0  6d 61 74 69 63 22 0d 0a  be 15 20 f1 8a 32 37 29  |matic".... ..27)|
00001bc0  22 20 20 70 72 6f 67 72  61 6d 22 0d 0a c8 15 20  |"  program".... |
00001bd0  f1 8a 32 37 29 22 20 20  72 75 6e 6e 69 6e 67 22  |..27)"  running"|
00001be0  0d 0a d2 3a 20 f1 22 4e  6f 2e 20 6f 66 20 6c 74  |...: ."No. of lt|
00001bf0  72 73 2e 22 3b 8a 31 33  29 22 50 65 72 6d 75 74  |rs.";.13)"Permut|
00001c00  61 74 69 6f 6e 73 22 3b  8a 32 37 29 22 63 6f 6e  |ations";.27)"con|
00001c10  74 69 6e 75 6f 75 73 6c  79 22 0d 0a dc 3a 20 f1  |tinuously"...: .|
00001c20  22 5f 5f 5f 5f 5f 5f 5f  5f 5f 5f 5f 5f 22 3b 8a  |"____________";.|
00001c30  31 33 29 22 5f 5f 5f 5f  5f 5f 5f 5f 5f 5f 5f 5f  |13)"____________|
00001c40  22 3b 8a 32 37 29 22 5f  5f 5f 5f 5f 5f 5f 5f 5f  |";.27)"_________|
00001c50  5f 5f 5f 22 0d 0a e6 25  20 f1 8a 36 29 22 32 22  |___"...% ..6)"2"|
00001c60  3b 8a 32 32 29 22 32 22  3b 8a 32 38 29 22 20 30  |;.22)"2";.28)" 0|
00001c70  2e 31 20 20 73 65 63 73  22 0d 0a f0 25 20 f1 8a  |.1  secs"...% ..|
00001c80  36 29 22 33 22 3b 8a 32  32 29 22 36 22 3b 8a 32  |6)"3";.22)"6";.2|
00001c90  38 29 22 20 30 2e 32 35  20 73 65 63 73 22 0d 0a  |8)" 0.25 secs"..|
00001ca0  fa 25 20 f1 8a 36 29 22  34 22 3b 8a 32 31 29 22  |.% ..6)"4";.21)"|
00001cb0  32 34 22 3b 8a 32 38 29  22 20 31 20 20 20 20 73  |24";.28)" 1    s|
00001cc0  65 63 22 0d 0b 04 27 20  f1 8a 36 29 22 35 22 3b  |ec"...' ..6)"5";|
00001cd0  8a 32 30 29 22 31 32 30  22 3b 8a 32 38 29 22 20  |.20)"120";.28)" |
00001ce0  35 20 20 20 20 73 65 63  73 22 0d 0b 0e 27 20 f1  |5    secs"...' .|
00001cf0  8a 36 29 22 36 22 3b 8a  32 30 29 22 37 32 30 22  |.6)"6";.20)"720"|
00001d00  3b 8a 32 38 29 22 32 37  20 20 20 20 73 65 63 73  |;.28)"27    secs|
00001d10  22 0d 0b 18 29 20 f1 8a  36 29 22 37 22 3b 8a 31  |"...) ..6)"7";.1|
00001d20  38 29 22 35 2c 30 34 30  22 3b 8a 32 38 29 22 20  |8)"5,040";.28)" |
00001d30  33 20 20 20 20 6d 69 6e  73 22 0d 0b 22 2a 20 f1  |3    mins".."* .|
00001d40  8a 36 29 22 38 22 3b 8a  31 37 29 22 34 30 2c 33  |.6)"8";.17)"40,3|
00001d50  32 30 22 3b 8a 32 38 29  22 32 31 2e 35 20 20 6d  |20";.28)"21.5  m|
00001d60  69 6e 73 22 0d 0b 2c 2a  20 f1 8a 36 29 22 39 22  |ins"..,* ..6)"9"|
00001d70  3b 8a 31 36 29 22 33 36  32 2c 38 38 30 22 3b 8a  |;.16)"362,880";.|
00001d80  32 38 29 22 20 33 2e 33  20 20 68 72 73 22 0d 0b  |28)" 3.3  hrs"..|
00001d90  36 48 20 f1 27 22 41 6e  79 20 6f 74 68 65 72 20  |6H .'"Any other |
00001da0  70 72 6f 67 72 61 6d 20  6d 6f 64 65 20 69 73 20  |program mode is |
00001db0  6f 66 20 63 6f 75 72 73  65 20 6d 75 63 68 73 6c  |of course muchsl|
00001dc0  6f 77 65 72 2c 20 61 73  20 69 73 20 70 72 69 6e  |ower, as is prin|
00001dd0  74 69 6e 67 2e 22 0d 0b  40 0f 20 f2 5f 43 4f 4e  |ting."..@. ._CON|
00001de0  54 49 4e 55 45 0d 0b 4a  06 20 e1 0d 0b 54 0d 20  |TINUE..J. ...T. |
00001df0  dd f2 5f 41 47 41 49 4e  0d 0b 5e 07 20 ef 33 0d  |.._AGAIN..^. .3.|
00001e00  0b 68 06 20 f5 0d 0b 72  2c 20 f1 8a 39 2c 32 34  |.h. ...r, ..9,24|
00001e10  29 3b bd 28 31 33 30 29  3b 22 41 6e 6f 74 68 65  |);.(130);"Anothe|
00001e20  72 20 77 6f 72 64 20 3f  20 20 28 59 2f 4e 29 22  |r word ?  (Y/N)"|
00001e30  3b 0d 0b 7c 09 20 47 24  3d be 0d 0b 86 29 20 fd  |;..|. G$=....) .|
00001e40  20 47 24 3d 22 59 22 20  84 20 47 24 3d 22 79 22  | G$="Y" . G$="y"|
00001e50  20 84 20 47 24 3d 22 4e  22 20 20 84 20 47 24 3d  | . G$="N"  . G$=|
00001e60  22 6e 22 0d 0b 90 2c 20  e7 20 47 24 3d 22 59 22  |"n"..., . G$="Y"|
00001e70  20 84 20 47 24 3d 22 79  22 20 8c 20 db 3a 20 e5  | . G$="y" . .: .|
00001e80  20 8d 64 64 42 3a 20 8b  20 e5 20 8d 64 40 43 0d  | .ddB: . . .d@C.|
00001e90  0b 9a 05 e1 0d 0b a4 0c  20 dd f2 5f 4c 4f 47 4f  |........ .._LOGO|
00001ea0  0d 0b ae 17 20 ef 31 32  2c 32 33 3b 38 32 30 32  |.... .12,23;8202|
00001eb0  3b 30 3b 30 3b 30 3b 0d  0b b8 13 20 ef 31 39 2c  |;0;0;0;.... .19,|
00001ec0  31 32 38 2c 31 33 35 3b  30 3b 0d 0b c2 0f 20 ef  |128,135;0;.... .|
00001ed0  31 39 2c 31 2c 32 3b 30  3b 0d 0b cc 0f 20 f0 34  |19,1,2;0;.... .4|
00001ee0  2c 31 36 30 2c 31 32 38  0d 0b d6 0f 20 f0 35 2c  |,160,128.... .5,|
00001ef0  31 36 30 2c 38 39 36 0d  0b e0 10 20 f0 35 2c 31  |160,896.... .5,1|
00001f00  31 32 30 2c 38 39 36 0d  0b ea 10 20 f0 35 2c 31  |120,896.... .5,1|
00001f10  31 32 30 2c 31 32 38 0d  0b f4 0f 20 f0 35 2c 31  |120,128.... .5,1|
00001f20  36 30 2c 31 32 38 0d 0b  fe 0f 20 f0 34 2c 31 36  |60,128.... .4,16|
00001f30  32 2c 31 33 32 0d 0c 08  0f 20 f0 35 2c 31 36 32  |2,132.... .5,162|
00001f40  2c 38 39 32 0d 0c 12 10  20 f0 35 2c 31 31 31 38  |,892.... .5,1118|
00001f50  2c 38 39 32 0d 0c 1c 10  20 f0 35 2c 31 31 31 38  |,892.... .5,1118|
00001f60  2c 31 33 32 0d 0c 26 0f  20 f0 35 2c 31 36 32 2c  |,132..&. .5,162,|
00001f70  31 33 32 0d 0c 30 0b 20  f0 30 2c 32 2c 30 0d 0c  |132..0. .0,2,0..|
00001f80  3a 0f 20 f0 35 2c 31 36  34 2c 38 39 32 0d 0c 44  |:. .5,164,892..D|
00001f90  10 20 f0 34 2c 31 31 31  36 2c 38 39 32 0d 0c 4e  |. .4,1116,892..N|
00001fa0  10 20 f0 35 2c 31 31 31  36 2c 31 33 32 0d 0c 58  |. .5,1116,132..X|
00001fb0  0b 20 f0 30 2c 30 2c 34  0d 0c 62 0f 20 f0 35 2c  |. .0,0,4..b. .5,|
00001fc0  31 36 34 2c 31 33 36 0d  0c 6c 0f 20 f0 35 2c 31  |164,136..l. .5,1|
00001fd0  36 34 2c 38 38 38 0d 0c  76 10 20 f0 35 2c 31 31  |64,888..v. .5,11|
00001fe0  31 36 2c 38 38 38 0d 0c  80 10 20 f0 35 2c 31 31  |16,888.... .5,11|
00001ff0  31 36 2c 31 33 36 0d 0c  8a 0c 20 f0 30 2c 2d 32  |16,136.... .0,-2|
00002000  2c 30 0d 0c 94 10 20 f0  35 2c 31 31 31 34 2c 38  |,0.... .5,1114,8|
00002010  38 38 0d 0c 9e 0f 20 f0  34 2c 31 36 38 2c 38 38  |88.... .4,168,88|
00002020  38 0d 0c a8 0f 20 f0 35  2c 31 36 38 2c 31 33 36  |8.... .5,168,136|
00002030  0d 0c b2 11 20 ef 32 39  2c 36 30 30 3b 37 30 30  |.... .29,600;700|
00002040  3b 0d 0c bc 0b 20 f0 34  2c 30 2c 30 0d 0c c6 06  |;.... .4,0,0....|
00002050  20 f7 0d 0c d0 0c 20 f3  20 58 25 2c 59 25 0d 0c  | ..... . X%,Y%..|
00002060  da 0d 20 f0 34 2c 58 25  2c 59 25 0d 0c e4 0b 20  |.. .4,X%,Y%.... |
00002070  49 3d a6 28 35 29 0d 0c  ee 0c 20 f3 20 58 25 2c  |I=.(5).... . X%,|
00002080  59 25 0d 0c f8 0e 20 f0  38 35 2c 58 25 2c 59 25  |Y%.... .85,X%,Y%|
00002090  0d 0d 02 0b 20 49 3d a6  28 35 29 0d 0d 0c 09 20  |.... I=.(5).... |
000020a0  50 25 3d 30 0d 0d 16 10  20 e3 20 50 25 3d 31 20  |P%=0.... . P%=1 |
000020b0  b8 20 32 34 0d 0d 20 0b  20 f0 34 2c 30 2c 30 0d  |. 24.. . .4,0,0.|
000020c0  0d 2a 0c 20 f3 20 58 25  2c 59 25 0d 0d 34 0e 20  |.*. . X%,Y%..4. |
000020d0  f0 38 35 2c 58 25 2c 59  25 0d 0d 3e 0b 20 49 3d  |.85,X%,Y%..>. I=|
000020e0  a6 28 35 29 0d 0d 48 0c  20 f3 20 58 25 2c 59 25  |.(5)..H. . X%,Y%|
000020f0  0d 0d 52 0e 20 f0 38 35  2c 58 25 2c 59 25 0d 0d  |..R. .85,X%,Y%..|
00002100  5c 0b 20 49 3d a6 28 35  29 0d 0d 66 06 20 ed 0d  |\. I=.(5)..f. ..|
00002110  0d 70 0b 20 f0 34 2c 30  2c 30 0d 0d 7a 0c 20 f3  |.p. .4,0,0..z. .|
00002120  20 58 25 2c 59 25 0d 0d  84 0e 20 f0 38 35 2c 58  | X%,Y%.... .85,X|
00002130  25 2c 59 25 0d 0d 8e 0b  20 49 3d a6 28 35 29 0d  |%,Y%.... I=.(5).|
00002140  0d 98 0f f0 34 2c 2d 36  30 2c 2d 31 37 35 0d 0d  |....4,-60,-175..|
00002150  a2 08 50 25 3d 30 0d 0d  ac 0b 20 f7 20 8d 74 48  |..P%=0.... . .tH|
00002160  4e 0d 0d b6 0c e3 20 50  25 3d 31 b8 39 0d 0d c0  |N..... P%=1.9...|
00002170  0b f3 20 58 25 2c 59 25  0d 0d ca 0c f0 35 2c 58  |.. X%,Y%.....5,X|
00002180  25 2c 59 25 0d 0d d4 05  ed 0d 0d de 0f f0 34 2c  |%,Y%..........4,|
00002190  31 35 30 2c 2d 31 39 38  0d 0d e8 08 50 25 3d 30  |150,-198....P%=0|
000021a0  0d 0d f2 0a f7 20 8d 74  52 4e 0d 0d fc 0b e3 50  |..... .tRN.....P|
000021b0  25 3d 31 b8 38 0d 0e 06  0b f3 20 58 25 2c 59 25  |%=1.8..... X%,Y%|
000021c0  0d 0e 10 0d f0 20 35 2c  58 25 2c 59 25 0d 0e 1a  |..... 5,X%,Y%...|
000021d0  05 ed 0d 0e 24 0e 20 f0  34 2c 34 2c 2d 31 35 30  |....$. .4,4,-150|
000021e0  0d 0e 2e 0f 20 f0 35 2c  32 34 2c 2d 31 37 35 0d  |.... .5,24,-175.|
000021f0  0e 38 0f 20 f0 35 2c 35  30 2c 2d 32 31 32 0d 0e  |.8. .5,50,-212..|
00002200  42 0f 20 f0 35 2c 37 32  2c 2d 31 36 38 0d 0e 4c  |B. .5,72,-168..L|
00002210  10 20 f0 34 2c 2d 39 34  2c 2d 34 30 30 0d 0e 56  |. .4,-94,-400..V|
00002220  10 20 f0 35 2c 32 33 36  2c 2d 34 30 30 0d 0e 60  |. .5,236,-400..`|
00002230  0c 20 f0 30 2c 2d 34 2c  30 0d 0e 6a 10 20 f0 35  |. .0,-4,0..j. .5|
00002240  2c 2d 39 34 2c 2d 34 30  30 0d 0e 74 e1 20 dc 30  |,-94,-400..t. .0|
00002250  2c 31 32 35 2c 32 35 2c  31 31 32 2c 35 30 2c 31  |,125,25,112,50,1|
00002260  30 30 2c 37 35 2c 38 37  2c 31 30 30 2c 39 30 2c  |00,75,87,100,90,|
00002270  31 32 35 2c 31 30 30 2c  31 35 30 2c 31 31 30 2c  |125,100,150,110,|
00002280  31 37 35 2c 31 30 30 2c  32 30 30 2c 39 34 2c 32  |175,100,200,94,2|
00002290  32 35 2c 37 35 2c 32 35  30 2c 32 35 2c 32 35 30  |25,75,250,25,250|
000022a0  2c 30 2c 32 35 30 2c 2d  32 35 2c 32 33 37 2c 2d  |,0,250,-25,237,-|
000022b0  35 30 2c 32 34 38 2c 2d  37 35 2c 32 37 32 2c 2d  |50,248,-75,272,-|
000022c0  31 30 30 2c 32 38 34 2c  2d 31 32 35 2c 32 37 36  |100,284,-125,276|
000022d0  2c 2d 31 35 30 2c 32 32  30 2c 2d 31 37 35 2c 32  |,-150,220,-175,2|
000022e0  30 30 2c 2d 31 38 38 2c  31 37 35 2c 2d 31 39 32  |00,-188,175,-192|
000022f0  2c 31 35 30 2c 2d 31 39  38 2c 31 32 35 2c 2d 32  |,150,-198,125,-2|
00002300  30 30 2c 31 30 30 2c 2d  32 30 35 2c 37 35 2c 2d  |00,100,-205,75,-|
00002310  31 37 35 2c 35 30 2c 2d  31 38 32 2c 32 35 2c 2d  |175,50,-182,25,-|
00002320  31 36 34 2c 30 2c 2d 31  35 30 0d 0e 7e ce 20 dc  |164,0,-150..~. .|
00002330  2d 32 35 2c 2d 31 35 36  2c 2d 35 30 2c 2d 31 37  |-25,-156,-50,-17|
00002340  35 2c 2d 37 35 2c 2d 32  31 36 2c 2d 31 30 30 2c  |5,-75,-216,-100,|
00002350  2d 32 32 36 2c 2d 31 32  35 2c 2d 32 32 36 2c 2d  |-226,-125,-226,-|
00002360  31 35 30 2c 2d 32 31 38  2c 2d 31 37 35 2c 2d 31  |150,-218,-175,-1|
00002370  38 38 2c 2d 31 38 30 2c  2d 31 35 30 2c 2d 31 38  |88,-180,-150,-18|
00002380  34 2c 2d 31 32 35 2c 2d  31 38 36 2c 2d 31 30 30  |4,-125,-186,-100|
00002390  2c 2d 31 38 30 2c 2d 37  35 2c 2d 31 37 30 2c 2d  |,-180,-75,-170,-|
000023a0  35 30 2c 2d 31 36 30 2c  2d 32 35 2c 2d 31 34 30  |50,-160,-25,-140|
000023b0  2c 30 2c 2d 31 34 30 2c  32 35 2c 2d 31 35 30 2c  |,0,-140,25,-150,|
000023c0  35 30 2c 2d 31 33 36 2c  37 35 2c 2d 31 32 35 2c  |50,-136,75,-125,|
000023d0  38 30 2c 2d 31 30 30 2c  39 30 2c 2d 37 35 2c 31  |80,-100,90,-75,1|
000023e0  31 32 2c 2d 35 30 2c 31  32 34 2c 2d 32 35 2c 31  |12,-50,124,-25,1|
000023f0  32 38 2c 30 2c 31 32 35  0d 0e 88 4d 20 dc 2d 32  |28,0,125...M .-2|
00002400  30 2c 2d 32 30 30 2c 30  2c 2d 32 32 35 2c 31 32  |0,-200,0,-225,12|
00002410  2c 2d 32 35 30 2c 32 34  2c 2d 32 37 35 2c 32 34  |,-250,24,-275,24|
00002420  2c 2d 33 30 30 2c 32 34  2c 2d 33 32 35 2c 32 34  |,-300,24,-325,24|
00002430  2c 2d 33 35 30 2c 32 34  2c 2d 33 37 35 2c 31 38  |,-350,24,-375,18|
00002440  2c 2d 34 30 30 0d 0e 92  4d 20 dc 31 32 30 2c 2d  |,-400...M .120,-|
00002450  32 32 35 2c 31 31 30 2c  2d 32 35 30 2c 31 30 34  |225,110,-250,104|
00002460  2c 2d 32 37 35 2c 31 30  34 2c 2d 33 30 30 2c 31  |,-275,104,-300,1|
00002470  30 34 2c 2d 33 32 35 2c  31 30 34 2c 2d 33 35 30  |04,-325,104,-350|
00002480  2c 31 31 36 2c 2d 33 37  35 2c 31 32 30 2c 2d 34  |,116,-375,120,-4|
00002490  30 30 0d 0e 9c 0d 20 49  3d a6 28 31 35 30 29 0d  |00.... I=.(150).|
000024a0  0e a6 20 20 f1 8a 31 33  2c 32 34 29 3b 22 42 20  |..  ..13,24);"B |
000024b0  52 20 4f 20 41 20 44 20  20 4f 20 41 20 4b 22 0d  |R O A D  O A K".|
000024c0  0e b0 0d 20 49 3d a6 28  33 30 30 29 0d 0e ba 08  |... I=.(300)....|
000024d0  20 ef 33 30 0d 0e c4 15  20 ef 32 33 3b 32 39 31  | .30.... .23;291|
000024e0  39 34 3b 30 3b 30 3b 30  3b 0d 0e ce 06 20 e1 0d  |94;0;0;0;.... ..|
000024f0  0e d8 0c 20 dd f2 5f 74  69 6d 65 0d 0e e2 13 20  |... .._time.... |
00002500  ea 20 74 2c 73 2c 73 25  2c 6d 25 2c 68 25 0d 0e  |. t,s,s%,m%,h%..|
00002510  ec 34 20 74 3d 91 3a 73  3d 74 2f 31 30 30 3a 73  |.4 t=.:s=t/100:s|
00002520  25 3d a8 28 73 29 3a 6d  25 3d a8 28 74 2f 36 30  |%=.(s):m%=.(t/60|
00002530  30 30 29 3a 68 25 3d a8  28 74 2f 33 36 30 30 30  |00):h%=.(t/36000|
00002540  30 29 0d 0e f6 2c 20 e7  20 73 25 3c 36 30 20 f1  |0)..., . s%<60 .|
00002550  27 22 54 69 6d 65 20 74  61 6b 65 6e 20 3d 20 22  |'"Time taken = "|
00002560  3b 73 3b 22 20 73 65 63  6f 6e 64 73 2e 22 0d 0f  |;s;" seconds."..|
00002570  00 49 20 e7 20 73 25 3e  3d 36 30 20 80 20 6d 25  |.I . s%>=60 . m%|
00002580  3c 36 30 20 f1 27 22 54  69 6d 65 20 74 61 6b 65  |<60 .'"Time take|
00002590  6e 20 3d 20 22 3b 6d 25  3b 22 20 6d 69 6e 75 74  |n = ";m%;" minut|
000025a0  65 28 73 29 20 22 3b 73  25 83 36 30 3b 22 20 73  |e(s) ";s%.60;" s|
000025b0  65 63 28 73 29 2e 22 0d  0f 0a 50 20 e7 20 6d 25  |ec(s)."...P . m%|
000025c0  3e 3d 36 30 20 f1 27 22  54 69 6d 65 20 74 61 6b  |>=60 .'"Time tak|
000025d0  65 6e 20 3d 20 22 3b 68  25 3b 22 20 68 6f 75 72  |en = ";h%;" hour|
000025e0  28 73 29 20 22 3b 6d 25  83 36 30 3b 22 20 6d 69  |(s) ";m%.60;" mi|
000025f0  6e 28 73 29 20 22 3b 73  25 83 36 30 3b 22 20 73  |n(s) ";s%.60;" s|
00002600  65 63 28 73 29 2e 22 0d  0f 14 06 20 e1 0d 0f 1e  |ec(s).".... ....|
00002610  0f 20 dd f2 5f 53 59 53  52 41 4e 44 0d 0f 28 06  |. .._SYSRAND..(.|
00002620  20 f5 0d 0f 32 34 20 f1  27 22 44 6f 20 79 6f 75  | ...24 .'"Do you|
00002630  20 77 61 6e 74 20 74 68  65 22 3b bd 31 33 33 3b  | want the";.133;|
00002640  22 52 61 6e 64 6f 6d 22  3b bd 31 33 35 3b 22 6f  |"Random";.135;"o|
00002650  72 20 74 68 65 22 0d 0f  3c 31 20 f1 bd 31 33 32  |r the"..<1 ..132|
00002660  3b 22 53 79 73 74 65 6d  61 74 69 63 22 3b bd 31  |;"Systematic";.1|
00002670  33 35 3b 22 67 65 6e 65  72 61 74 6f 72 20 3f 20  |35;"generator ? |
00002680  28 52 2f 53 29 22 3b 0d  0f 46 09 20 47 24 3d be  |(R/S)";..F. G$=.|
00002690  0d 0f 50 28 20 fd 20 47  24 3d 22 53 22 20 84 20  |..P( . G$="S" . |
000026a0  47 24 3d 22 73 22 20 84  20 47 24 3d 22 52 22 20  |G$="s" . G$="R" |
000026b0  84 20 47 24 3d 22 72 22  0d 0f 5a 4a 20 e7 20 47  |. G$="r"..ZJ . G|
000026c0  24 3d 22 53 22 20 84 20  47 24 3d 22 73 22 20 8c  |$="S" . G$="s" .|
000026d0  20 73 79 73 74 25 3d 2d  31 3a 20 f1 8a 33 34 29  | syst%=-1: ..34)|
000026e0  3b bd 31 33 32 3b 47 24  3a 20 8b 20 73 79 73 74  |;.132;G$: . syst|
000026f0  25 3d 30 3a 20 f1 8a 33  34 29 3b bd 31 33 33 3b  |%=0: ..34);.133;|
00002700  47 24 0d 0f 64 06 20 e1  0d 0f 6e 05 20 0d 0f 78  |G$..d. ...n. ..x|
00002710  0c 20 dd f2 5f 66 69 6e  64 0d 0f 82 67 20 e7 20  |. .._find...g . |
00002720  41 4e 24 3d 66 69 6e 64  24 20 80 20 74 69 6d 65  |AN$=find$ . time|
00002730  64 25 20 ef 37 3a 20 f1  bd 31 33 31 3b bd 31 33  |d% .7: ..131;.13|
00002740  36 3b 41 4e 24 3a 20 f1  27 22 54 68 65 72 65 27  |6;AN$: .'"There'|
00002750  73 20 79 6f 75 72 22 3b  bd 31 33 31 3b 22 61 6e  |s your";.131;"an|
00002760  61 67 72 61 6d 22 3b bd  31 33 35 3b 22 21 22 3a  |agram";.135;"!":|
00002770  20 f2 5f 74 69 6d 65 3a  20 f2 5f 41 47 41 49 4e  | ._time: ._AGAIN|
00002780  0d 0f 8c 06 20 e1 0d 0f  96 0e 20 dd f2 5f 52 61  |.... ..... .._Ra|
00002790  6e 64 6f 6d 0d 0f a0 0c  20 ea 20 6c 25 2c 58 25  |ndom.... . l%,X%|
000027a0  0d 0f aa 10 20 6c 25 3d  a9 28 57 4f 52 44 24 29  |.... l%=.(WORD$)|
000027b0  0d 0f b4 06 20 f5 0d 0f  be 16 20 72 61 6e 64 25  |.... ..... rand%|
000027c0  3d 28 6c 25 2b 31 29 2a  b3 28 31 29 0d 0f c8 15  |=(l%+1)*.(1)....|
000027d0  20 e7 20 72 61 6e 64 25  3c 31 20 e5 20 8d 74 7e  | . rand%<1 . .t~|
000027e0  4f 0d 0f d2 10 20 e3 20  58 25 3d 31 20 b8 20 6c  |O.... . X%=1 . l|
000027f0  25 0d 0f dc 3e 20 61 24  3d c2 57 4f 52 44 24 2c  |%...> a$=.WORD$,|
00002800  6c 25 2d 72 61 6e 64 25  29 3a 62 24 3d c1 57 4f  |l%-rand%):b$=.WO|
00002810  52 44 24 2c 72 61 6e 64  25 2c 31 29 3a 63 24 3d  |RD$,rand%,1):c$=|
00002820  c0 57 4f 52 44 24 2c 72  61 6e 64 25 2d 31 29 0d  |.WORD$,rand%-1).|
00002830  0f e6 11 20 41 4e 24 3d  61 24 2b 62 24 2b 63 24  |... AN$=a$+b$+c$|
00002840  0d 0f f0 09 20 ed 20 58  25 0d 0f fa 19 20 f4 20  |.... . X%.... . |
00002850  50 52 4f 43 64 69 73 70  6c 61 79 5f 72 61 6e 64  |PROCdisplay_rand|
00002860  6f 6d 0d 10 04 15 20 f1  8a 31 35 29 46 25 3b 22  |om.... ..15)F%;"|
00002870  20 20 22 3b 41 4e 24 0d  10 0e 0c 20 46 25 3d 46  |  ";AN$.... F%=F|
00002880  25 2b 31 0d 10 18 0b 20  f2 5f 66 69 6e 64 0d 10  |%+1.... ._find..|
00002890  22 14 20 e7 20 72 75 6e  25 3d 30 20 f2 5f 4e 45  |". . run%=0 ._NE|
000028a0  58 54 0d 10 2c 26 20 e7  20 72 75 6e 25 20 80 20  |XT..,& . run% . |
000028b0  70 61 67 65 64 25 20 80  20 46 25 83 32 31 3d 30  |paged% . F%.21=0|
000028c0  20 f2 5f 53 48 49 46 54  0d 10 36 0e 20 57 4f 52  | ._SHIFT..6. WOR|
000028d0  44 24 3d 41 4e 24 0d 10  40 08 20 fd 20 a3 0d 10  |D$=AN$..@. . ...|
000028e0  4a 06 20 e1 0d 10 54 0d  20 dd f2 5f 65 72 72 6f  |J. ...T. .._erro|
000028f0  72 0d 10 5e 07 20 ef 33  0d 10 68 25 20 e7 20 9f  |r..^. .3..h% . .|
00002900  3d 31 37 20 8c 20 ef 33  2c 31 35 3a 20 db 3a 20  |=17 . .3,15: .: |
00002910  e5 20 8d 74 76 43 20 8b  20 f6 3a 20 e0 0d 10 72  |. .tvC . .: ...r|
00002920  06 20 e1 0d 10 7c 15 20  dd f2 64 69 73 70 6c 61  |. ...|. ..displa|
00002930  79 5f 72 61 6e 64 6f 6d  0d 10 86 24 20 f1 27 22  |y_random...$ .'"|
00002940  52 61 6e 64 6f 6d 20 6e  6f 2e 3d 20 22 3b 72 61  |Random no.= ";ra|
00002950  6e 64 25 3a 20 49 3d a6  28 34 30 29 0d 10 90 20  |nd%: I=.(40)... |
00002960  20 f1 22 52 49 47 48 54  24 20 20 20 20 3d 20 22  | ."RIGHT$    = "|
00002970  3b 61 24 3a 20 49 3d a6  28 34 30 29 0d 10 9a 20  |;a$: I=.(40)... |
00002980  20 f1 22 4d 49 44 24 20  20 20 20 20 20 3d 20 22  | ."MID$      = "|
00002990  3b 62 24 3a 20 49 3d a6  28 34 30 29 0d 10 a4 20  |;b$: I=.(40)... |
000029a0  20 f1 22 4c 45 46 54 24  20 20 20 20 20 3d 20 22  | ."LEFT$     = "|
000029b0  3b 63 24 3a 20 49 3d a6  28 34 30 29 0d 10 ae 31  |;c$: I=.(40)...1|
000029c0  20 f1 22 77 6f 72 64 24  22 3b 22 20 20 20 20 20  | ."word$";"     |
000029d0  3d 20 22 3b 61 24 3b 22  2b 22 3b 62 24 3b 22 2b  |= ";a$;"+";b$;"+|
000029e0  22 3b 63 24 3a 20 49 3d  a6 28 34 30 29 0d 10 b8  |";c$: I=.(40)...|
000029f0  06 20 e1 0d ff                                    |. ...|
000029f5
Utils/ANAGRAM.m0
Utils/ANAGRAM.m1
Utils/ANAGRAM.m2
Utils/ANAGRAM.m4
Utils/ANAGRAM.m5