Let's solve Wordle with Python!
First, let's download the English words dataset from NLTK:
We're only interested in 5-letter words:
Next, we could rank our options by sorting by letter frequency in the English language, from https://en.wikipedia.org/wiki/Letter_frequency :
Now, let's calculate which word gives us the best chance of hitting letters:
Now let's see which word has the highest score – this one should be our first Wordle guess:
Okay, so let's start with ATONE:
Now let's filter out only those words that have O in the third place and don't have the letters ATNE:
Now let's also add a filter for words that DO contain the letter R, but don't have in the fifth spot:
And now we just rinse and repeat:
GROUF doesn't sound like a word so let's go with GROUP :D