Differences From Artifact [3076579102b4d2b4]:
File hangman/dict.retro part of check-in [8b7b6c9b3c] - remove files.retro from hangman by crc on 2010-10-25 18:56:05. [annotate] [view]
To Artifact [acfd9685b8c01dde]:
File hangman/dict.retro part of check-in [819dd8a89b] - hangman: use string' in dict.retro instead of rolling a custom lowercase routine by crc on 2010-10-25 20:20:43. [annotate] [view]
@@ -7,8 +7,9 @@
( ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ )
with files'
with math'
+with string'
( --[ Variables ]--------------------------------------------- )
: sys-dict "wordlist.txt" :r ;
@@ -37,12 +38,7 @@
"Error: Can't close dictionary." puts then ;
( --[ Retrieval ]--------------------------------------------- )
-: >lower ( c-c' ) dup 'A 'Z within if 32 + then ;
-
-: lowercase ( $-$' ) repeat dup @ 0 =if drop ;then
- dup @ >lower over ! 1+ again ;
-
-: get-word ( -$ ) rand-word dict-word lowercase dict-word ;
+: get-word ( -$ ) rand-word dict-word toLower dict-word ;
( ============================================================ )