@@ -12,9 +12,9 @@ include files.retro ( --[ Variables ]--------------------------------------------- ) -: sys-dict s" wordlist.txt" :r ; +: sys-dict "wordlist.txt" :r ; variable dict 0 dict ! here 80 allot constant dict-word variable dict-size @@ -21,9 +21,9 @@ ( --[ Access ]------------------------------------------------ ) : open-dict ( -h ) sys-dict open dup 0 =if - cr ." Error: can't open dictionary." then ; + cr "Error: can't open dictionary." puts then ; : initialise ( - ) dict @ 0 =if open-dict 0; dup dict ! size dict-size ! then ; : rand-off ( -n ) dict-size @ toRandom ; @@ -35,9 +35,9 @@ dup @ 10 =if 0 swap ! ;; else 1+ then again ; : rand-word ( - ) rand-pos >line readline ; : close-dict ( - ) dict @ close 0 =if - ." Error: Can't close dictionary." then ; + "Error: Can't close dictionary." puts then ; ( --[ Retrieval ]--------------------------------------------- ) : >lower ( c-c' ) dup 'A 'Z within if 32 + then ;