Just a tool to assist in solving a Wordle puzzle. The real purpose is to learn the Go language.
Run with:
go run .
Enter the word you guess, and then the outcome of the guess, using the following options:
c
- letter is correcte
- letter is used elsewherex
- letter is incorrect
You are then presented with the list of candidate words, sorted by words with the most number of unique letters first.
Then the cycle continues with another prompt.
Use Control-C
to bail out.
Here is a sample session solving the word ennui
:
prompt% go run . Enter guess: fried Enter outcome: xxeex --------------------------------------------------------------------------- mesia pokie zowie aisle aizle alkie aspie bagie begin zinke belit yowie bemix benis benji yince besit besti bewig bezil yetis bigae xenic bilge binge biome biose xenia boeti bogie bonie bosie bowie cavie withe cesti ciels winze cleik cogie cosie cozie cutie eatin winge eight wince eikon elain elchi wiels eloin elsin email emoji enlit walie enoki entia envoi eosin vygie equip ethic vogie etuis genic vleis vitae visne genio genip viewy views vieux vexil gleis gynie helio helix hemic hemin hiems hinge venti homie ickle ileac uptie ileum ileus image imbue untie inbye incle inept ingle inkle umpie isnae ulzie istle items ixtle jakie jaxie ulyie tozie jolie --------------------------------------------------------------------------- Enter guess: begin Enter outcome: xexee --------------------------------------------------------------------------- minae visne envoi zinke incle inept inkle isnae yince liane pince enoki minke mince sient minse moeni naevi niche winze wince miens since liens jinne siens nisse nieve niess niece ennui inane --------------------------------------------------------------------------- Enter guess: mince Enter outcome: xecxe --------------------------------------------------------------------------- ennui --------------------------------------------------------------------------- Enter guess: ^Csignal: interrupt
go run . <<DOG
plant
xxxxx
DOG
See LICENSE.
The valid-words.txt file was sourced from this gist.
Obviously you need go
installed. Exercise left to reader. I used VS Code
to develop.
Run tests with:
go test -v
Use https://towardsdatascience.com/a-frequency-analysis-on-wordle-9c5778283363 and rank words that contain letter that are the most average frequency of letters in 5-letter words. I.e. favour using e
over z
as it’s more frequent. Still prefer words with the most number of unique letters.
Letter | Rating |
---|---|
a | 52 |
e | 48 |
s | 41 |
o | 32 |
r | 31 |
i | 30 |
l | 26 |
t | 25 |
n | 25 |
u | 21 |
d | 17 |
c | 16 |
y | 15 |
m | 15 |
p | 14 |
h | 14 |
b | 13 |
g | 12 |
k | 11 |
f | 8 |
w | 7 |
v | 6 |
z | 3 |
j | 2 |
x | 2 |
q | 1 |