home *** CD-ROM | disk | FTP | other *** search
/ Really Useful CD 1 / ReallyUsefulCD1.iso / extras / progutils / mcbits / quicksort2 < prev    next >
Unknown  |  1988-12-28  |  1.5 KB

open in: MacOS 8.1     |     Win98     |     DOS

view JSON data     |     view as text


This file was not able to be converted.
This format is not currently supported by dexvert.

ConfidenceProgramDetectionMatch TypeSupport
100% file data default
100% xdgMime image/x-tga default



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 0d 00 0a 11 f4 20 3e 51 | 75 69 63 6b 53 6f 72 74 |..... >Q|uickSort|
|00000010| 32 0d 00 14 05 f4 0d 00 | 1e 04 0d 00 28 04 0d 00 |2.......|....(...|
|00000020| 32 04 0d 00 3c 05 3a 0d | 00 46 07 eb 20 30 0d 00 |2...<.:.|.F.. 0..|
|00000030| 50 08 f2 61 73 73 0d 00 | 5a 14 f1 22 41 52 4d 20 |P..ass..|Z.."ARM |
|00000040| 51 75 69 63 6b 73 6f 72 | 74 22 0d 00 64 21 e8 22 |Quicksor|t"..d!."|
|00000050| 48 6f 77 20 6d 61 6e 79 | 20 6e 75 6d 62 65 72 73 |How many| numbers|
|00000060| 20 74 6f 20 73 6f 72 74 | 22 4e 25 0d 00 6e 0d de | to sort|"N%..n..|
|00000070| 20 61 25 20 4e 25 2a 34 | 0d 00 78 16 f1 27 22 49 | a% N%*4|..x..'"I|
|00000080| 6e 69 74 69 61 6c 69 73 | 69 6e 67 2e 2e 22 0d 00 |nitialis|ing.."..|
|00000090| 82 0f e3 20 49 25 3d 31 | 20 b8 20 4e 25 0d 00 8c |... I%=1| . N%...|
|000000a0| 14 61 25 21 28 49 25 2a | 34 29 3d b3 28 31 30 30 |.a%!(I%*|4)=.(100|
|000000b0| 29 0d 00 96 05 ed 0d 00 | a0 0a f2 70 72 69 6e 74 |).......|...print|
|000000c0| 0d 00 aa 07 41 3d a5 0d | 00 b4 09 41 25 3d 61 25 |....A=..|...A%=a%|
|000000d0| 0d 00 be 08 42 25 3d 31 | 0d 00 c8 09 43 25 3d 4e |....B%=1|....C%=N|
|000000e0| 25 0d 00 d2 13 f1 27 22 | 53 6f 72 74 69 6e 67 20 |%.....'"|Sorting |
|000000f0| 6e 6f 77 22 0d 00 dc 07 | d1 3d 30 0d 00 e6 0b d6 |now"....|.=0.....|
|00000100| 20 71 73 6f 72 74 0d 00 | f0 18 f1 22 54 69 6d 65 | qsort..|..."Time|
|00000110| 20 74 61 6b 65 6e 20 22 | 3b 91 2f 31 30 30 0d 00 | taken "|;./100..|
|00000120| fa 1e f1 22 50 72 65 73 | 73 20 61 20 6b 65 79 20 |..."Pres|s a key |
|00000130| 66 6f 72 20 72 65 73 75 | 6c 74 73 22 0d 01 04 09 |for resu|lts"....|
|00000140| 6b 65 79 3d a5 0d 01 0e | 0a f2 70 72 69 6e 74 0d |key=....|..print.|
|00000150| 01 18 05 f1 0d 01 22 05 | e0 0d 01 2c 05 3a 0d 01 |......".|...,.:..|
|00000160| 36 09 dd f2 61 73 73 0d | 01 40 0c de 20 63 25 20 |6...ass.|.@.. c% |
|00000170| 35 30 30 0d 01 4a 20 70 | 6f 69 6e 74 65 72 3d 30 |500..J p|ointer=0|
|00000180| 3a 6c 65 66 74 3d 31 3a | 72 69 67 68 74 3d 32 3a |:left=1:|right=2:|
|00000190| 69 3d 33 0d 01 54 22 6c | 61 73 74 3d 34 3a 74 65 |i=3..T"l|ast=4:te|
|000001a0| 6d 70 31 3d 35 3a 74 65 | 6d 70 32 3d 36 3a 74 65 |mp1=5:te|mp2=6:te|
|000001b0| 6d 70 33 3d 37 0d 01 5e | 17 73 70 3d 31 33 3a 6c |mp3=7..^|.sp=13:l|
|000001c0| 69 6e 6b 3d 31 34 3a 70 | 63 3d 31 35 0d 01 68 15 |ink=14:p|c=15..h.|
|000001d0| e3 20 70 61 73 73 25 3d | 30 20 b8 20 33 20 88 20 |. pass%=|0 . 3 . |
|000001e0| 33 0d 01 72 09 50 25 3d | 63 25 0d 01 7c 0e 5b 4f |3..r.P%=|c%..|.[O|
|000001f0| 50 54 20 70 61 73 73 25 | 0d 01 86 0a 2e 71 73 6f |PT pass%|.....qso|
|00000200| 72 74 0d 01 90 26 53 54 | 4d 46 44 20 28 73 70 29 |rt...&ST|MFD (sp)|
|00000210| 21 2c 7b 6c 65 66 74 2c | 72 69 67 68 74 2c 6c 61 |!,{left,|right,la|
|00000220| 73 74 2c 6c 69 6e 6b 7d | 0d 01 9a 12 43 4d 50 20 |st,link}|....CMP |
|00000230| 6c 65 66 74 2c 72 69 67 | 68 74 0d 01 a4 26 4c 44 |left,rig|ht...&LD|
|00000240| 4d 47 45 46 44 20 28 73 | 70 29 21 2c 7b 6c 65 66 |MGEFD (s|p)!,{lef|
|00000250| 74 2c 72 69 67 68 74 2c | 6c 61 73 74 2c 70 63 7d |t,right,|last,pc}|
|00000260| 0d 01 ae 23 4c 44 52 20 | 74 65 6d 70 31 2c 5b 70 |...#LDR |temp1,[p|
|00000270| 6f 69 6e 74 65 72 2c 6c | 65 66 74 2c 4c 53 4c 20 |ointer,l|eft,LSL |
|00000280| 23 32 5d 0d 01 b8 18 41 | 44 44 20 74 65 6d 70 33 |#2]....A|DD temp3|
|00000290| 2c 6c 65 66 74 2c 72 69 | 67 68 74 0d 01 c2 1a 4d |,left,ri|ght....M|
|000002a0| 4f 56 20 74 65 6d 70 33 | 2c 74 65 6d 70 33 2c 4c |OV temp3|,temp3,L|
|000002b0| 53 52 20 23 31 0d 01 cc | 24 4c 44 52 20 74 65 6d |SR #1...|$LDR tem|
|000002c0| 70 32 2c 5b 70 6f 69 6e | 74 65 72 2c 74 65 6d 70 |p2,[poin|ter,temp|
|000002d0| 33 2c 4c 53 4c 20 23 32 | 5d 0d 01 d6 23 53 54 52 |3,LSL #2|]...#STR|
|000002e0| 20 74 65 6d 70 32 2c 5b | 70 6f 69 6e 74 65 72 2c | temp2,[|pointer,|
|000002f0| 6c 65 66 74 2c 4c 53 4c | 20 23 32 5d 0d 01 e0 24 |left,LSL| #2]...$|
|00000300| 53 54 52 20 74 65 6d 70 | 31 2c 5b 70 6f 69 6e 74 |STR temp|1,[point|
|00000310| 65 72 2c 74 65 6d 70 33 | 2c 4c 53 4c 20 23 32 5d |er,temp3|,LSL #2]|
|00000320| 0d 01 ea 11 4d 4f 56 20 | 6c 61 73 74 2c 6c 65 66 |....MOV |last,lef|
|00000330| 74 0d 01 f4 11 41 44 44 | 20 69 2c 6c 65 66 74 2c |t....ADD| i,left,|
|00000340| 23 31 0d 01 fe 09 2e 6c | 6f 6f 70 0d 02 08 20 4c |#1.....l|oop... L|
|00000350| 44 52 20 74 65 6d 70 31 | 2c 5b 70 6f 69 6e 74 65 |DR temp1|,[pointe|
|00000360| 72 2c 69 2c 4c 53 4c 20 | 23 32 5d 0d 02 12 23 4c |r,i,LSL |#2]...#L|
|00000370| 44 52 20 74 65 6d 70 32 | 2c 5b 70 6f 69 6e 74 65 |DR temp2|,[pointe|
|00000380| 72 2c 6c 65 66 74 2c 4c | 53 4c 20 23 32 5d 0d 02 |r,left,L|SL #2]..|
|00000390| 1c 13 43 4d 50 20 74 65 | 6d 70 31 2c 74 65 6d 70 |..CMP te|mp1,temp|
|000003a0| 32 0d 02 26 16 42 47 45 | 20 67 72 65 61 74 65 72 |2..&.BGE| greater|
|000003b0| 6f 72 65 71 75 61 6c 0d | 02 30 14 41 44 44 20 6c |orequal.|.0.ADD l|
|000003c0| 61 73 74 2c 6c 61 73 74 | 2c 23 31 0d 02 3a 23 4c |ast,last|,#1..:#L|
|000003d0| 44 52 20 74 65 6d 70 31 | 2c 5b 70 6f 69 6e 74 65 |DR temp1|,[pointe|
|000003e0| 72 2c 6c 61 73 74 2c 4c | 53 4c 20 23 32 5d 0d 02 |r,last,L|SL #2]..|
|000003f0| 44 20 4c 44 52 20 74 65 | 6d 70 32 2c 5b 70 6f 69 |D LDR te|mp2,[poi|
|00000400| 6e 74 65 72 2c 69 2c 4c | 53 4c 20 23 32 5d 0d 02 |nter,i,L|SL #2]..|
|00000410| 4e 23 53 54 52 20 74 65 | 6d 70 32 2c 5b 70 6f 69 |N#STR te|mp2,[poi|
|00000420| 6e 74 65 72 2c 6c 61 73 | 74 2c 4c 53 4c 20 23 32 |nter,las|t,LSL #2|
|00000430| 5d 0d 02 58 20 53 54 52 | 20 74 65 6d 70 31 2c 5b |]..X STR| temp1,[|
|00000440| 70 6f 69 6e 74 65 72 2c | 69 2c 4c 53 4c 20 23 32 |pointer,|i,LSL #2|
|00000450| 5d 0d 02 62 13 2e 67 72 | 65 61 74 65 72 6f 72 65 |]..b..gr|eaterore|
|00000460| 71 75 61 6c 0d 02 6c 0e | 41 44 44 20 69 2c 69 2c |qual..l.|ADD i,i,|
|00000470| 23 31 0d 02 76 0f 43 4d | 50 20 69 2c 72 69 67 68 |#1..v.CM|P i,righ|
|00000480| 74 0d 02 80 0c 42 4c 45 | 20 6c 6f 6f 70 0d 02 8a |t....BLE| loop...|
|00000490| 23 4c 44 52 20 74 65 6d | 70 31 2c 5b 70 6f 69 6e |#LDR tem|p1,[poin|
|000004a0| 74 65 72 2c 6c 65 66 74 | 2c 4c 53 4c 20 23 32 5d |ter,left|,LSL #2]|
|000004b0| 0d 02 94 23 4c 44 52 20 | 74 65 6d 70 32 2c 5b 70 |...#LDR |temp2,[p|
|000004c0| 6f 69 6e 74 65 72 2c 6c | 61 73 74 2c 4c 53 4c 20 |ointer,l|ast,LSL |
|000004d0| 23 32 5d 0d 02 9e 23 53 | 54 52 20 74 65 6d 70 32 |#2]...#S|TR temp2|
|000004e0| 2c 5b 70 6f 69 6e 74 65 | 72 2c 6c 65 66 74 2c 4c |,[pointe|r,left,L|
|000004f0| 53 4c 20 23 32 5d 0d 02 | a8 23 53 54 52 20 74 65 |SL #2]..|.#STR te|
|00000500| 6d 70 31 2c 5b 70 6f 69 | 6e 74 65 72 2c 6c 61 73 |mp1,[poi|nter,las|
|00000510| 74 2c 4c 53 4c 20 23 32 | 5d 0d 02 b2 17 53 54 4d |t,LSL #2|]....STM|
|00000520| 46 44 20 28 73 70 29 21 | 2c 7b 72 69 67 68 74 7d |FD (sp)!|,{right}|
|00000530| 0d 02 bc 12 53 55 42 20 | 52 32 2c 6c 61 73 74 2c |....SUB |R2,last,|
|00000540| 23 31 0d 02 c6 0c 42 4c | 20 71 73 6f 72 74 0d 02 |#1....BL| qsort..|
|00000550| d0 17 4c 44 4d 46 44 20 | 28 73 70 29 21 2c 7b 72 |..LDMFD |(sp)!,{r|
|00000560| 69 67 68 74 7d 0d 02 da | 12 41 44 44 20 72 31 2c |ight}...|.ADD r1,|
|00000570| 6c 61 73 74 2c 23 31 0d | 02 e4 0c 42 4c 20 71 73 |last,#1.|...BL qs|
|00000580| 6f 72 74 0d 02 ee 24 4c | 44 4d 46 44 20 28 73 70 |ort...$L|DMFD (sp|
|00000590| 29 21 2c 7b 6c 65 66 74 | 2c 72 69 67 68 74 2c 6c |)!,{left|,right,l|
|000005a0| 61 73 74 2c 70 63 7d 0d | 02 f8 05 5d 0d 03 02 0b |ast,pc}.|...]....|
|000005b0| ed 20 70 61 73 73 25 0d | 03 0c 05 e1 0d 03 16 0b |. pass%.|........|
|000005c0| dd f2 70 72 69 6e 74 0d | 03 20 04 0d 03 2a 0f e3 |..print.|. ...*..|
|000005d0| 20 49 25 3d 31 20 b8 20 | 4e 25 0d 03 34 11 f1 20 | I%=1 . |N%..4.. |
|000005e0| 61 25 21 28 49 25 2a 34 | 29 2c 3b 0d 03 3e 05 ed |a%!(I%*4|),;..>..|
|000005f0| 0d 03 48 05 e1 0d ff | |..H.... | |
+--------+-------------------------+-------------------------+--------+--------+