start tok64 d64-nPz1qI
0 REM"@0:directory reader",8
1 ]reciter:]speed70:POKE53280,6:POKE53281,6:PRINT"{light blue}{clear}
2 OPEN1,8,0,"$":POKE781,1:SYS65478:GETa$,a$:e$=CHR$(.):q$=CHR$(34)
3 GETa$,a$,h$,l$:IFstTHENSYS65484:CLOSE1
4 t=ASC(h$+e$)+256*ASC(l$+e$):PRINTt;:IFrTHENGOSUB23
5 r=r-1:u$="":IFr=-1THENu$="disk name is "
6 GETa$:PRINTa$;:IFa$="b"THENt$=t$+" free":PRINT"locks free":w$="":GOTO18
7 IFa$<>q$THEN6
8 GETa$:PRINTa$;:IFa$<>q$THENu$=u$+a$:GOTO8
9 IFr=-1THEN11
10 GETw$:PRINTw$;:IFw$=" "THEN10
11 GETa$:PRINTa$;:IFa$<>""THEN11
12 IFw$="p"THENw$="program
13 IFw$="s"THENw$="sequential
14 IFw$="r"THENw$="relai-tiv
15 IFw$="u"THENw$="user
16 IFw$="d"ORw$="*"THENw$="
17 IFLEN(w$)=1THENw$="un-nown file type
18 PRINT:IFu$<>""AND(w$<>""ORr=-1)THENu$=u$+".":sayu$
19 IFw$<>""THENw$=w$+".":sayw$
20 IFt$<>""ANDt$<>"no blocks"THENt$=t$+".":sayt$
21 IFRIGHT$(t$,2)="e."THENSYS65484:CLOSE1:END
22 GOTO3
23 t$="":l=t:x=INT(t/100):t=t-x*100
24 IFx>.THENt$=STR$(x)+"hondred":IFt>.THENt$=t$+"&
25 x=INT(t/10):ONxGOTO34,26,27,28,29,28,28,28,28:GOTO30
26 t$=t$+" twenty":GOTO30
27 t$=t$+" thirty":GOTO30
28 t$=t$+STR$(x)+"te":GOTO30
29 t$=t$+" fifty
30 IFl=.THENt$="no blocks":RETURN
31 IFt-x*10=.THENt$=t$+" blocks":RETURN
32 t$=t$+STR$(t-x*10)+" block":IFl<>1THENt$=t$+"s
33 RETURN
34 ONt-10GOTO35,36,37,38,39,38,38,38,38:t$=t$+" ten blocks":RETURN
35 t$=t$+" eleven blocks":RETURN
36 t$=t$+" twelve blocks":RETURN
37 t$=t$+" thirteen blocks":RETURN
38 t$=t$+STR$(t-10)+"teen blocks":RETURN
39 t$=t$+" fifteen blocks":RETURN
40 REM (c)1991 softwolves software/mr.p
41 REM created for sys pd 91-11-24.     39 rem "directory reader" for "sam"
stop tok64
(bastext 1.0)