Handbook
Glossary
guess>chars ( secret guess -- seq )
Vocabulary
wordlet
Inputs
secret
an
object
guess
an
object
Outputs
seq
an
object
Definition
USING:
arrays
colors
hashtables
io.styles
kernel
sequences
sequences.extras
strings
;
IN:
wordlet
:
guess>chars
( secret guess -- seq )
[
[
=
]
[
drop
1string
]
{
}
2reject-map-as
]
2keep
[
[
nip
1string
]
[
=
]
2bi
[
COLOR:
green
]
[
2dup
member-of?
[
[
remove-first-of
]
[
COLOR:
yellow
]
bi
]
[
COLOR:
gray
]
if
]
if
background
associate
2array
]
{
}
2map-as
nip
;