home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Compute! Gazette 1990 February
/
1990-02.d64
/
mlprogramming2
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-09-20
|
630b
|
30 lines
10 print"[147][155]":poke53280,0:poke53281,0
20 printtab(14)"wordcounter"
100 data 169,0,141,240,37,141,241,37
110 data 141,255,37,162,1,32,198,255
120 data 32,228,255,168,185,0,38
130 data 205,255,37,240,14,141,255
140 data 37,168,240,8,238,240,37,208,3
150 data 238,241,37,165,144,240,226
160 data 76,204,255
200 for j=9472 to 9520
210 read x:t=t+x
220 poke j,x
230 next j
240 if t<>7145 then stop
500 c=9728:c0=c+128
510 for j=0 to 255:poke j+c,0:next j
520 for j=48 to 57:poke j+c,1:next j
530 for j=65 to 90
540 poke j+c,1:poke j+c0,1
550 next j
600 open 15,8,15
610 input "filename";f$
620 open 1,8,2,f$
630 input#15,a,a$,a1,a2:if a<>0 then print a$:stop
640 sys 9472
650 close 1
660 close 15
670 w=peek(9712)+peek(9713)*256
680 print "file has";w;"words."