Home » Personal collection » Acorn ADFS disks » Electron_User_Group » EUG_13.ADF » InkeyNg

InkeyNg

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 » Personal collection » Acorn ADFS disks » Electron_User_Group » EUG_13.ADF
Filename: InkeyNg
Read OK:
File size: 0964 bytes
Load address: FFFF1D00
Exec address: FFFF8023
Duplicates

There is 1 duplicate copy of this file in the archive:

File contents
   10REM ***************************
   20REM Print Negative Inkey Values
   30REM by R.A.Dimond
   40REM January 1993
   50REM ***************************
   60 
   70MODE6
   80PROCinit
   90PROCsort
  100CLS
  110PRINTTAB(5,1)"Print Negative Inkey Values"
  120PRINT'"Screen or Printer? (S/P)"
  130REPEAT:a%=INSTR("SsPp",GET$):UNTILa%
  140MODE3
  150IFa%<3 PROCscreen ELSE PROCprinter
  160END
  170DEFPROCscreen:VDU14:PROCprint:ENDPROC
  180DEFPROCprinter
  190VDU15,2,1,27,1,54,1,116,1,1
  200PROCprint:VDU3:ENDPROC
  210DEFPROCprint
  220PRINT'CHR$201;STRING$(65,CHR$205);CHR$187
  230PRINTCHR$186;SPC22;"Key Values for INKEY-";SPC22;CHR$186
  240PRINTCHR$204;STRING$(65,CHR$205);CHR$185
  250PRINTCHR$186;SPC22;"Alphabetical Listing";SPC23;CHR$186
  260PRINTCHR$199;STRING$(21,CHR$196);CHR$194;STRING$(21,CHR$196);CHR$194;STRING$(21,CHR$196);CHR$182
  270FORi%=1TO 18
  280PRINTTAB(0);CHR$186;TAB(2);B$(i%,0);TAB(13);"-";B%(i%);TAB(19);B$(i%,1);TAB(22);CHR$179;TAB(24);B$(i%+18,0);TAB(35);"-";B%(i%+18);TAB(41);B$(i%+18,1);TAB(44);CHR$179;TAB(46);B$(i%+36,0);TAB(57);"-";B%(i%+36);TAB(63);B$(i%+36,1);
  290PRINTTAB(66);CHR$186
  300NEXT
  310PRINTCHR$204;STRING$(21,CHR$205);CHR$207;STRING$(21,CHR$205);CHR$207;STRING$(21,CHR$205);CHR$185
  320PRINTCHR$186;SPC24;"Numerical Listing";SPC24;CHR$186
  330PRINTCHR$199;STRING$(21,CHR$196);CHR$194;STRING$(21,CHR$196);CHR$194;STRING$(21,CHR$196);CHR$182
  340FORi%=1TO 18
  350PRINTTAB(0);CHR$186;TAB(2);A$(i%,0);TAB(13);"-";A%(i%);TAB(19);A$(i%,1);TAB(22);CHR$179;TAB(24);A$(i%+18,0);TAB(35);"-";A%(i%+18);TAB(41);A$(i%+18,1);TAB(44);CHR$179;TAB(46);A$(i%+36,0);TAB(57);"-";A%(i%+36);TAB(63);A$(i%+36,1);
  360PRINTTAB(66);CHR$186
  370NEXT
  380PRINTCHR$200;STRING$(21,CHR$205);CHR$207;STRING$(21,CHR$205);CHR$207;STRING$(21,CHR$205);CHR$188
  390VDU3:ENDPROC
  400DEFPROCinit
  410DIM A%(54),B%(54),A$(54,1),B$(54,1)
  420FORI=1TO 54
  430READ A$,A%
  440IFA$="c" A$=","
  450A%(I)=A%:B%(I)=A%
  460A$(I,0)=A$:B$(I,0)=A$:A$(I,1)=RIGHT$(STR$~-A%,2):B$(I,1)=RIGHT$(STR$~-A%,2)
  470NEXT
  480ENDPROC
  490DEFPROCsort
  500stack%=12:DIMsl%(stack%),sr%(stack%),W%(1),W$(1,1)
  510top%=1
  520sl%(1)=1
  530sr%(1)=54
  540REM Take next from stack
  550l%=sl%(top%)
  560r%=sr%(top%)
  570top%=top%-1
  580REM separate A(1) to A(r%)
  590i%=l%
  600j%=r%
  610X%=A%(INT((l%+r%)/2))
  620IFA%(i%)<X% THENi%=i%+1:GOTO620
  630IFX%<A%(j%) THENj%=j%-1:GOTO630
  640IFi%>j% THEN700
  650W%(0)=A%(i%):W$(0,0)=A$(i%,0):W$(0,1)=A$(i%,1)
  660A%(i%)=A%(j%):A$(i%,0)=A$(j%,0):A$(i%,1)=A$(j%,1)
  670A%(j%)=W%(0):A$(j%,0)=W$(0,0):A$(j%,1)=W$(0,1)
  680i%=i%+1
  690j%=j%-1
  700IFi%<=j% THEN620
  710IFi%>=r% THEN760
  720REM sort the partition
  730top%=top%+1
  740sl%(top%)=i%
  750sr%(top%)=r%
  760r%=j%
  770IFl%<r% THEN590
  780IFtop%<>0 THEN550
  790ENDPROC
  800DATA A,66,B,101,C,83,D,51,E,35,F,68,G,84,H,85,I,38,J,70,K,71,L,87,M,102,N,86,O,55,P,56,Q,17,R,52,S,82,T,36,U,54,V,100,W,34,X,67,Y,69,Z,98,1,49,2,50,3,18,4,19,5,20,6,53,7,37,8,22,9,39,0,40
  810DATA -,24,;,88,:,73,c,103,.,104,/,105,SPACE,99,ESCAPE,113,CAPS LK,65,CTRL,2,SHIFT,1,DELETE,90,COPY,106,RETURN,74,CUR UP,58,CUR DOWN,42,CUR LEFT,26,CUR RIGHT,122

!� ***************************
!� Print Negative Inkey Values
� by R.A.Dimond
(� January 1993
2!� ***************************
< 
F�6
P	�init
Z	�sort
d�
n'�5,1)"Print Negative Inkey Values"
x �'"Screen or Printer? (S/P)"
��:a%=�"SsPp",�):�a%
��3
��a%<3 �screen � �printer
��
���screen:�14:�print:�
�
��printer
��15,2,1,27,1,54,1,116,1,1
��print:�3:�
���print
��'�201;�65,�205);�187
�.�186;�22;"Key Values for INKEY-";�22;�186
��204;�65,�205);�185
�-�186;�22;"Alphabetical Listing";�23;�186
6�199;�21,�196);�194;�21,�196);�194;�21,�196);�182

�i%=1� 18
��0);�186;�2);B$(i%,0);�13);"-";B%(i%);�19);B$(i%,1);�22);�179;�24);B$(i%+18,0);�35);"-";B%(i%+18);�41);B$(i%+18,1);�44);�179;�46);B$(i%+36,0);�57);"-";B%(i%+36);�63);B$(i%+36,1);
"�66);�186
,�
66�204;�21,�205);�207;�21,�205);�207;�21,�205);�185
@*�186;�24;"Numerical Listing";�24;�186
J6�199;�21,�196);�194;�21,�196);�194;�21,�196);�182
T
�i%=1� 18
^��0);�186;�2);A$(i%,0);�13);"-";A%(i%);�19);A$(i%,1);�22);�179;�24);A$(i%+18,0);�35);"-";A%(i%+18);�41);A$(i%+18,1);�44);�179;�46);A$(i%+36,0);�57);"-";A%(i%+36);�63);A$(i%+36,1);
h�66);�186
r�
|6�200;�21,�205);�207;�21,�205);�207;�21,�205);�188
��3:�
�
��init
�%� A%(54),B%(54),A$(54,1),B$(54,1)
��I=1� 54
�� A$,A%
��A$="c" A$=","
�A%(I)=A%:B%(I)=A%
�=A$(I,0)=A$:B$(I,0)=A$:A$(I,1)=��~-A%,2):B$(I,1)=��~-A%,2)
��
��
�
��sort
�4stack%=12:�sl%(stack%),sr%(stack%),W%(1),W$(1,1)
�
top%=1
sl%(1)=1

sr%(1)=54
� Take next from stack
&l%=sl%(top%)
0r%=sr%(top%)
:top%=top%-1
D� separate A(1) to A(r%)
N	i%=l%
X	j%=r%
bX%=A%(�((l%+r%)/2))
l�A%(i%)<X% �i%=i%+1:�DlB
v�X%<A%(j%) �j%=j%-1:�DvB
��i%>j% ��t|B
�2W%(0)=A%(i%):W$(0,0)=A$(i%,0):W$(0,1)=A$(i%,1)
�5A%(i%)=A%(j%):A$(i%,0)=A$(j%,0):A$(i%,1)=A$(j%,1)
�2A%(j%)=W%(0):A$(j%,0)=W$(0,0):A$(j%,1)=W$(0,1)
�i%=i%+1
�j%=j%-1
��i%<=j% ��DlB
��i%>=r% ��dxB
�� sort the partition
�top%=top%+1
�sl%(top%)=i%
�sr%(top%)=r%
�	r%=j%
�l%<r% ��DNB
�top%<>0 ��TfB
�
 �� A,66,B,101,C,83,D,51,E,35,F,68,G,84,H,85,I,38,J,70,K,71,L,87,M,102,N,86,O,55,P,56,Q,17,R,52,S,82,T,36,U,54,V,100,W,34,X,67,Y,69,Z,98,1,49,2,50,3,18,4,19,5,20,6,53,7,37,8,22,9,39,0,40
*�� -,24,;,88,:,73,c,103,.,104,/,105,SPACE,99,ESCAPE,113,CAPS LK,65,CTRL,2,SHIFT,1,DELETE,90,COPY,106,RETURN,74,CUR UP,58,CUR DOWN,42,CUR LEFT,26,CUR RIGHT,122
�
00000000  0d 00 0a 21 f4 20 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |...!. **********|
00000010  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
00000020  2a 0d 00 14 21 f4 20 50  72 69 6e 74 20 4e 65 67  |*...!. Print Neg|
00000030  61 74 69 76 65 20 49 6e  6b 65 79 20 56 61 6c 75  |ative Inkey Valu|
00000040  65 73 0d 00 1e 13 f4 20  62 79 20 52 2e 41 2e 44  |es..... by R.A.D|
00000050  69 6d 6f 6e 64 0d 00 28  12 f4 20 4a 61 6e 75 61  |imond..(.. Janua|
00000060  72 79 20 31 39 39 33 0d  00 32 21 f4 20 2a 2a 2a  |ry 1993..2!. ***|
00000070  2a 2a 2a 2a 2a 2a 2a 2a  2a 2a 2a 2a 2a 2a 2a 2a  |****************|
00000080  2a 2a 2a 2a 2a 2a 2a 2a  0d 00 3c 05 20 0d 00 46  |********..<. ..F|
00000090  06 eb 36 0d 00 50 09 f2  69 6e 69 74 0d 00 5a 09  |..6..P..init..Z.|
000000a0  f2 73 6f 72 74 0d 00 64  05 db 0d 00 6e 27 f1 8a  |.sort..d....n'..|
000000b0  35 2c 31 29 22 50 72 69  6e 74 20 4e 65 67 61 74  |5,1)"Print Negat|
000000c0  69 76 65 20 49 6e 6b 65  79 20 56 61 6c 75 65 73  |ive Inkey Values|
000000d0  22 0d 00 78 20 f1 27 22  53 63 72 65 65 6e 20 6f  |"..x .'"Screen o|
000000e0  72 20 50 72 69 6e 74 65  72 3f 20 28 53 2f 50 29  |r Printer? (S/P)|
000000f0  22 0d 00 82 17 f5 3a 61  25 3d a7 22 53 73 50 70  |".....:a%=."SsPp|
00000100  22 2c be 29 3a fd 61 25  0d 00 8c 06 eb 33 0d 00  |",.):.a%.....3..|
00000110  96 1c e7 61 25 3c 33 20  f2 73 63 72 65 65 6e 20  |...a%<3 .screen |
00000120  8b 20 f2 70 72 69 6e 74  65 72 0d 00 a0 05 e0 0d  |. .printer......|
00000130  00 aa 19 dd f2 73 63 72  65 65 6e 3a ef 31 34 3a  |.....screen:.14:|
00000140  f2 70 72 69 6e 74 3a e1  0d 00 b4 0d dd f2 70 72  |.print:.......pr|
00000150  69 6e 74 65 72 0d 00 be  1d ef 31 35 2c 32 2c 31  |inter.....15,2,1|
00000160  2c 32 37 2c 31 2c 35 34  2c 31 2c 31 31 36 2c 31  |,27,1,54,1,116,1|
00000170  2c 31 0d 00 c8 0f f2 70  72 69 6e 74 3a ef 33 3a  |,1.....print:.3:|
00000180  e1 0d 00 d2 0b dd f2 70  72 69 6e 74 0d 00 dc 19  |.......print....|
00000190  f1 27 bd 32 30 31 3b c4  36 35 2c bd 32 30 35 29  |.'.201;.65,.205)|
000001a0  3b bd 31 38 37 0d 00 e6  2e f1 bd 31 38 36 3b 89  |;.187......186;.|
000001b0  32 32 3b 22 4b 65 79 20  56 61 6c 75 65 73 20 66  |22;"Key Values f|
000001c0  6f 72 20 49 4e 4b 45 59  2d 22 3b 89 32 32 3b bd  |or INKEY-";.22;.|
000001d0  31 38 36 0d 00 f0 18 f1  bd 32 30 34 3b c4 36 35  |186......204;.65|
000001e0  2c bd 32 30 35 29 3b bd  31 38 35 0d 00 fa 2d f1  |,.205);.185...-.|
000001f0  bd 31 38 36 3b 89 32 32  3b 22 41 6c 70 68 61 62  |.186;.22;"Alphab|
00000200  65 74 69 63 61 6c 20 4c  69 73 74 69 6e 67 22 3b  |etical Listing";|
00000210  89 32 33 3b bd 31 38 36  0d 01 04 36 f1 bd 31 39  |.23;.186...6..19|
00000220  39 3b c4 32 31 2c bd 31  39 36 29 3b bd 31 39 34  |9;.21,.196);.194|
00000230  3b c4 32 31 2c bd 31 39  36 29 3b bd 31 39 34 3b  |;.21,.196);.194;|
00000240  c4 32 31 2c bd 31 39 36  29 3b bd 31 38 32 0d 01  |.21,.196);.182..|
00000250  0e 0d e3 69 25 3d 31 b8  20 31 38 0d 01 18 b7 f1  |...i%=1. 18.....|
00000260  8a 30 29 3b bd 31 38 36  3b 8a 32 29 3b 42 24 28  |.0);.186;.2);B$(|
00000270  69 25 2c 30 29 3b 8a 31  33 29 3b 22 2d 22 3b 42  |i%,0);.13);"-";B|
00000280  25 28 69 25 29 3b 8a 31  39 29 3b 42 24 28 69 25  |%(i%);.19);B$(i%|
00000290  2c 31 29 3b 8a 32 32 29  3b bd 31 37 39 3b 8a 32  |,1);.22);.179;.2|
000002a0  34 29 3b 42 24 28 69 25  2b 31 38 2c 30 29 3b 8a  |4);B$(i%+18,0);.|
000002b0  33 35 29 3b 22 2d 22 3b  42 25 28 69 25 2b 31 38  |35);"-";B%(i%+18|
000002c0  29 3b 8a 34 31 29 3b 42  24 28 69 25 2b 31 38 2c  |);.41);B$(i%+18,|
000002d0  31 29 3b 8a 34 34 29 3b  bd 31 37 39 3b 8a 34 36  |1);.44);.179;.46|
000002e0  29 3b 42 24 28 69 25 2b  33 36 2c 30 29 3b 8a 35  |);B$(i%+36,0);.5|
000002f0  37 29 3b 22 2d 22 3b 42  25 28 69 25 2b 33 36 29  |7);"-";B%(i%+36)|
00000300  3b 8a 36 33 29 3b 42 24  28 69 25 2b 33 36 2c 31  |;.63);B$(i%+36,1|
00000310  29 3b 0d 01 22 0e f1 8a  36 36 29 3b bd 31 38 36  |);.."...66);.186|
00000320  0d 01 2c 05 ed 0d 01 36  36 f1 bd 32 30 34 3b c4  |..,....66..204;.|
00000330  32 31 2c bd 32 30 35 29  3b bd 32 30 37 3b c4 32  |21,.205);.207;.2|
00000340  31 2c bd 32 30 35 29 3b  bd 32 30 37 3b c4 32 31  |1,.205);.207;.21|
00000350  2c bd 32 30 35 29 3b bd  31 38 35 0d 01 40 2a f1  |,.205);.185..@*.|
00000360  bd 31 38 36 3b 89 32 34  3b 22 4e 75 6d 65 72 69  |.186;.24;"Numeri|
00000370  63 61 6c 20 4c 69 73 74  69 6e 67 22 3b 89 32 34  |cal Listing";.24|
00000380  3b bd 31 38 36 0d 01 4a  36 f1 bd 31 39 39 3b c4  |;.186..J6..199;.|
00000390  32 31 2c bd 31 39 36 29  3b bd 31 39 34 3b c4 32  |21,.196);.194;.2|
000003a0  31 2c bd 31 39 36 29 3b  bd 31 39 34 3b c4 32 31  |1,.196);.194;.21|
000003b0  2c bd 31 39 36 29 3b bd  31 38 32 0d 01 54 0d e3  |,.196);.182..T..|
000003c0  69 25 3d 31 b8 20 31 38  0d 01 5e b7 f1 8a 30 29  |i%=1. 18..^...0)|
000003d0  3b bd 31 38 36 3b 8a 32  29 3b 41 24 28 69 25 2c  |;.186;.2);A$(i%,|
000003e0  30 29 3b 8a 31 33 29 3b  22 2d 22 3b 41 25 28 69  |0);.13);"-";A%(i|
000003f0  25 29 3b 8a 31 39 29 3b  41 24 28 69 25 2c 31 29  |%);.19);A$(i%,1)|
00000400  3b 8a 32 32 29 3b bd 31  37 39 3b 8a 32 34 29 3b  |;.22);.179;.24);|
00000410  41 24 28 69 25 2b 31 38  2c 30 29 3b 8a 33 35 29  |A$(i%+18,0);.35)|
00000420  3b 22 2d 22 3b 41 25 28  69 25 2b 31 38 29 3b 8a  |;"-";A%(i%+18);.|
00000430  34 31 29 3b 41 24 28 69  25 2b 31 38 2c 31 29 3b  |41);A$(i%+18,1);|
00000440  8a 34 34 29 3b bd 31 37  39 3b 8a 34 36 29 3b 41  |.44);.179;.46);A|
00000450  24 28 69 25 2b 33 36 2c  30 29 3b 8a 35 37 29 3b  |$(i%+36,0);.57);|
00000460  22 2d 22 3b 41 25 28 69  25 2b 33 36 29 3b 8a 36  |"-";A%(i%+36);.6|
00000470  33 29 3b 41 24 28 69 25  2b 33 36 2c 31 29 3b 0d  |3);A$(i%+36,1);.|
00000480  01 68 0e f1 8a 36 36 29  3b bd 31 38 36 0d 01 72  |.h...66);.186..r|
00000490  05 ed 0d 01 7c 36 f1 bd  32 30 30 3b c4 32 31 2c  |....|6..200;.21,|
000004a0  bd 32 30 35 29 3b bd 32  30 37 3b c4 32 31 2c bd  |.205);.207;.21,.|
000004b0  32 30 35 29 3b bd 32 30  37 3b c4 32 31 2c bd 32  |205);.207;.21,.2|
000004c0  30 35 29 3b bd 31 38 38  0d 01 86 08 ef 33 3a e1  |05);.188.....3:.|
000004d0  0d 01 90 0a dd f2 69 6e  69 74 0d 01 9a 25 de 20  |......init...%. |
000004e0  41 25 28 35 34 29 2c 42  25 28 35 34 29 2c 41 24  |A%(54),B%(54),A$|
000004f0  28 35 34 2c 31 29 2c 42  24 28 35 34 2c 31 29 0d  |(54,1),B$(54,1).|
00000500  01 a4 0c e3 49 3d 31 b8  20 35 34 0d 01 ae 0b f3  |....I=1. 54.....|
00000510  20 41 24 2c 41 25 0d 01  b8 12 e7 41 24 3d 22 63  | A$,A%.....A$="c|
00000520  22 20 41 24 3d 22 2c 22  0d 01 c2 15 41 25 28 49  |" A$=","....A%(I|
00000530  29 3d 41 25 3a 42 25 28  49 29 3d 41 25 0d 01 cc  |)=A%:B%(I)=A%...|
00000540  3d 41 24 28 49 2c 30 29  3d 41 24 3a 42 24 28 49  |=A$(I,0)=A$:B$(I|
00000550  2c 30 29 3d 41 24 3a 41  24 28 49 2c 31 29 3d c2  |,0)=A$:A$(I,1)=.|
00000560  c3 7e 2d 41 25 2c 32 29  3a 42 24 28 49 2c 31 29  |.~-A%,2):B$(I,1)|
00000570  3d c2 c3 7e 2d 41 25 2c  32 29 0d 01 d6 05 ed 0d  |=..~-A%,2)......|
00000580  01 e0 05 e1 0d 01 ea 0a  dd f2 73 6f 72 74 0d 01  |..........sort..|
00000590  f4 34 73 74 61 63 6b 25  3d 31 32 3a de 73 6c 25  |.4stack%=12:.sl%|
000005a0  28 73 74 61 63 6b 25 29  2c 73 72 25 28 73 74 61  |(stack%),sr%(sta|
000005b0  63 6b 25 29 2c 57 25 28  31 29 2c 57 24 28 31 2c  |ck%),W%(1),W$(1,|
000005c0  31 29 0d 01 fe 0a 74 6f  70 25 3d 31 0d 02 08 0c  |1)....top%=1....|
000005d0  73 6c 25 28 31 29 3d 31  0d 02 12 0d 73 72 25 28  |sl%(1)=1....sr%(|
000005e0  31 29 3d 35 34 0d 02 1c  1a f4 20 54 61 6b 65 20  |1)=54..... Take |
000005f0  6e 65 78 74 20 66 72 6f  6d 20 73 74 61 63 6b 0d  |next from stack.|
00000600  02 26 10 6c 25 3d 73 6c  25 28 74 6f 70 25 29 0d  |.&.l%=sl%(top%).|
00000610  02 30 10 72 25 3d 73 72  25 28 74 6f 70 25 29 0d  |.0.r%=sr%(top%).|
00000620  02 3a 0f 74 6f 70 25 3d  74 6f 70 25 2d 31 0d 02  |.:.top%=top%-1..|
00000630  44 1c f4 20 73 65 70 61  72 61 74 65 20 41 28 31  |D.. separate A(1|
00000640  29 20 74 6f 20 41 28 72  25 29 0d 02 4e 09 69 25  |) to A(r%)..N.i%|
00000650  3d 6c 25 0d 02 58 09 6a  25 3d 72 25 0d 02 62 17  |=l%..X.j%=r%..b.|
00000660  58 25 3d 41 25 28 a8 28  28 6c 25 2b 72 25 29 2f  |X%=A%(.((l%+r%)/|
00000670  32 29 29 0d 02 6c 1d e7  41 25 28 69 25 29 3c 58  |2))..l..A%(i%)<X|
00000680  25 20 8c 69 25 3d 69 25  2b 31 3a e5 8d 44 6c 42  |% .i%=i%+1:..DlB|
00000690  0d 02 76 1d e7 58 25 3c  41 25 28 6a 25 29 20 8c  |..v..X%<A%(j%) .|
000006a0  6a 25 3d 6a 25 2d 31 3a  e5 8d 44 76 42 0d 02 80  |j%=j%-1:..DvB...|
000006b0  10 e7 69 25 3e 6a 25 20  8c 8d 74 7c 42 0d 02 8a  |..i%>j% ..t|B...|
000006c0  32 57 25 28 30 29 3d 41  25 28 69 25 29 3a 57 24  |2W%(0)=A%(i%):W$|
000006d0  28 30 2c 30 29 3d 41 24  28 69 25 2c 30 29 3a 57  |(0,0)=A$(i%,0):W|
000006e0  24 28 30 2c 31 29 3d 41  24 28 69 25 2c 31 29 0d  |$(0,1)=A$(i%,1).|
000006f0  02 94 35 41 25 28 69 25  29 3d 41 25 28 6a 25 29  |..5A%(i%)=A%(j%)|
00000700  3a 41 24 28 69 25 2c 30  29 3d 41 24 28 6a 25 2c  |:A$(i%,0)=A$(j%,|
00000710  30 29 3a 41 24 28 69 25  2c 31 29 3d 41 24 28 6a  |0):A$(i%,1)=A$(j|
00000720  25 2c 31 29 0d 02 9e 32  41 25 28 6a 25 29 3d 57  |%,1)...2A%(j%)=W|
00000730  25 28 30 29 3a 41 24 28  6a 25 2c 30 29 3d 57 24  |%(0):A$(j%,0)=W$|
00000740  28 30 2c 30 29 3a 41 24  28 6a 25 2c 31 29 3d 57  |(0,0):A$(j%,1)=W|
00000750  24 28 30 2c 31 29 0d 02  a8 0b 69 25 3d 69 25 2b  |$(0,1)....i%=i%+|
00000760  31 0d 02 b2 0b 6a 25 3d  6a 25 2d 31 0d 02 bc 11  |1....j%=j%-1....|
00000770  e7 69 25 3c 3d 6a 25 20  8c 8d 44 6c 42 0d 02 c6  |.i%<=j% ..DlB...|
00000780  11 e7 69 25 3e 3d 72 25  20 8c 8d 64 78 42 0d 02  |..i%>=r% ..dxB..|
00000790  d0 18 f4 20 73 6f 72 74  20 74 68 65 20 70 61 72  |... sort the par|
000007a0  74 69 74 69 6f 6e 0d 02  da 0f 74 6f 70 25 3d 74  |tition....top%=t|
000007b0  6f 70 25 2b 31 0d 02 e4  10 73 6c 25 28 74 6f 70  |op%+1....sl%(top|
000007c0  25 29 3d 69 25 0d 02 ee  10 73 72 25 28 74 6f 70  |%)=i%....sr%(top|
000007d0  25 29 3d 72 25 0d 02 f8  09 72 25 3d 6a 25 0d 03  |%)=r%....r%=j%..|
000007e0  02 10 e7 6c 25 3c 72 25  20 8c 8d 44 4e 42 0d 03  |...l%<r% ..DNB..|
000007f0  0c 12 e7 74 6f 70 25 3c  3e 30 20 8c 8d 54 66 42  |...top%<>0 ..TfB|
00000800  0d 03 16 05 e1 0d 03 20  bc dc 20 41 2c 36 36 2c  |....... .. A,66,|
00000810  42 2c 31 30 31 2c 43 2c  38 33 2c 44 2c 35 31 2c  |B,101,C,83,D,51,|
00000820  45 2c 33 35 2c 46 2c 36  38 2c 47 2c 38 34 2c 48  |E,35,F,68,G,84,H|
00000830  2c 38 35 2c 49 2c 33 38  2c 4a 2c 37 30 2c 4b 2c  |,85,I,38,J,70,K,|
00000840  37 31 2c 4c 2c 38 37 2c  4d 2c 31 30 32 2c 4e 2c  |71,L,87,M,102,N,|
00000850  38 36 2c 4f 2c 35 35 2c  50 2c 35 36 2c 51 2c 31  |86,O,55,P,56,Q,1|
00000860  37 2c 52 2c 35 32 2c 53  2c 38 32 2c 54 2c 33 36  |7,R,52,S,82,T,36|
00000870  2c 55 2c 35 34 2c 56 2c  31 30 30 2c 57 2c 33 34  |,U,54,V,100,W,34|
00000880  2c 58 2c 36 37 2c 59 2c  36 39 2c 5a 2c 39 38 2c  |,X,67,Y,69,Z,98,|
00000890  31 2c 34 39 2c 32 2c 35  30 2c 33 2c 31 38 2c 34  |1,49,2,50,3,18,4|
000008a0  2c 31 39 2c 35 2c 32 30  2c 36 2c 35 33 2c 37 2c  |,19,5,20,6,53,7,|
000008b0  33 37 2c 38 2c 32 32 2c  39 2c 33 39 2c 30 2c 34  |37,8,22,9,39,0,4|
000008c0  30 0d 03 2a a1 dc 20 2d  2c 32 34 2c 3b 2c 38 38  |0..*.. -,24,;,88|
000008d0  2c 3a 2c 37 33 2c 63 2c  31 30 33 2c 2e 2c 31 30  |,:,73,c,103,.,10|
000008e0  34 2c 2f 2c 31 30 35 2c  53 50 41 43 45 2c 39 39  |4,/,105,SPACE,99|
000008f0  2c 45 53 43 41 50 45 2c  31 31 33 2c 43 41 50 53  |,ESCAPE,113,CAPS|
00000900  20 4c 4b 2c 36 35 2c 43  54 52 4c 2c 32 2c 53 48  | LK,65,CTRL,2,SH|
00000910  49 46 54 2c 31 2c 44 45  4c 45 54 45 2c 39 30 2c  |IFT,1,DELETE,90,|
00000920  43 4f 50 59 2c 31 30 36  2c 52 45 54 55 52 4e 2c  |COPY,106,RETURN,|
00000930  37 34 2c 43 55 52 20 55  50 2c 35 38 2c 43 55 52  |74,CUR UP,58,CUR|
00000940  20 44 4f 57 4e 2c 34 32  2c 43 55 52 20 4c 45 46  | DOWN,42,CUR LEF|
00000950  54 2c 32 36 2c 43 55 52  20 52 49 47 48 54 2c 31  |T,26,CUR RIGHT,1|
00000960  32 32 0d ff                                       |22..|
00000964
InkeyNg.m0
InkeyNg.m1
InkeyNg.m2
InkeyNg.m4
InkeyNg.m5