Refinements to Best Wordle Second Guess

Objective

In the example described at Best First Two Guesses in Wordle, where a first guess of “slate” results in the pattern “**G*Y”, we decided that our best chance for winning in three tries was to choose “berry”. If, however, we restrict our second guess to one of the possible targets, then we would choose “beard”, “heady”, or “heard” as our second guess. While these three choices are equivalent if our goal is to win in three tries, it might be the case that one of them is better if our secondary goal is to win within 4 tries. 

For this analysis, we will still assume that our primary goal is to win in three tries, but our secondary goal, failing this, is to win in at most 4 tries. Note that in order to win on the 4th try, assuming that we haven’t guessed the target word in the first 3 tries, we need to choose one of the remaining words from the list of targets that are compatible with the patterns of our first two guesses. We could, of course, change our strategy, which might be beneficial to improve our odds of guessing the target on the 5th or 6th try, but no other strategy is better for the 4th try.

As stated previously, after a second guess of “heady”, “heard”, or “beard”, 9 possible patterns can result as shown in Figure 1. Thus, as previously noted the probability of winning within 3 tries for any of these is 9/12 = 75%.

Patterns after second guess

Figure 1 – Patterns for best second guesses

Analysis for “heady”

Now, what is the probability of a win in 4 tries? We need to count which of the 12 target words results in a win within 4 tries. Let’s start with “heady”. Clearly, we obtain a win in 2 tries when Wordle returns the first pattern (“GGGGG”), and a win in 3 tries for the next 6 patterns (since there is only one choice for the third guess.

If Wordle responds to “heady” with “*GGGG”, then there are two choices. If you guess correctly you win in 3, but if not, you win in 4. With 1 or 2 choices, you always win within 4 tries.

If Wordle responds to “heady” with “YGG**”, then there are 3 choices (“beach”, “peach”, or “reach”) for the third guess. If you pick any one of these (say “beach”), then if you guess correctly then you win in 3 tries, but if you guess incorrectly, then only one pattern remains, namely (*GGGG”) but with two targets (“peach” and “reach” after a third guess of “beach”). If you guess correctly, you win in 4, but if you guess incorrectly you win in 5.

Thus, after a second guess of “heady”, you have 1 chance to win in 2, 8 chances to win in 3, 2 chances to win in 4, and 1 chance to win in 5. The probability of a win within 4 tries is therefore 11/12.

Analysis for “beard”

Now, let’s look at the situation if your second guess is “beard”. The first 8 patterns in Figure 1 result in the same outcomes as for “heady”. Now we look at the case where the response to “beard” is “GGG*”. There are 3 possible targets (“rearm”, “weary”, “yearn”). Figure 2 displays the outcomes for each of the 3 choices for the third guess.

Responses after "beard"

Figure 2 – When Wordle responds to “beard” with “*GGG*”

If “rearm” is your third guess, then the situation is similar to that described for “heady”. If you guess correctly (Wordle response is “GGGG”), then you win in 3. But if not, then only one pattern remains, namely “*GGG*”, but with two targets possible (“weary” and “yearn”). Thus, once again you have an 11/12 chance of winning within 4 tries, but a 1/12 probability of needing 5 tries to guess the target word.

The situation is better if you choose “weary” or “yearn” as your third guess. If you choose “weary” as your third guess and this is correct, then you win in 3 tries. If not, then two patterns remain: “*GGG*” and “*GGGY”. In the first case, you choose “rearm” as your fourth guess and win. In the second case, you choose “yearn” as your fourth guess and win. Thus, in all cases, you win within 4 tries.

Further observations

The situation is similar if you pick “yearn” as your third guess since Wordle responds with 3 patterns, one for each of the remaining targets.

Thus, if your first guess of “slate” results in the pattern “**G*Y”, you should select “beard” as your second guess, instead of “heady”, since although both of these results in a win within 3 tries with the same probability, namely 75%, “beard” has a higher probability of a win within 4 tries, namely 100% for “beard” and 11/12 = 91.7% for “heady”.

It turns out that “heard” also provides a 75% chance of a win within 3 tries and a 100% chance within 4 tries, and so is just as good a second guess as “beard”.

The situation becomes more complicated when one of the patterns after the second guess has 4 or more targets. Now, when there is a choice between two second guesses with the same chance of a win within 3 tries, it may turn out that the chances of a win within 4 tries are the same, and so we may need to look at the chance of a win within 5 tries.

It can also happen that in more complicated situations, the second guess that maximizes the probability of a win within 3 tries won’t guarantee a win even within 6 tries with 100% probability. 

Another example

Suppose that “G*GY*” is returned after the initial guess of “slate”. Now suppose we use a second guess of “drift”. There are 10 non-zero patterns, 8 of them have only 1 potential target, 1 (“*Y**G”) has 2 potential targets (“smart”, “start”), and 1 (“****Y”) has 4 potential targets (“stamp”, “stank”, “stack”, “stash”).

The probability of a win within 3 tries is 10/14; we lose only when the second pattern is “*Y**G” or “****Y”, and we guess wrong.  After “*Y**G” even if we guess wrong on the third try, we will guess correctly on the 4th try. Only after “****Y” is there a chance that we won’t guess correctly on the 4th try. Now suppose that “stash” is the target word. If our 3rd, 4th, and 5th guesses are “stamp”, “stank”, and “stack”, then we won’t guess correctly until the 6th try. Thus, we have a 12/14 chance of winning within 4 tries, a 13/14 chance of winning within 5 tries, and we will always win within 6 tries.

Here we have not used any pattern information from the 3rd or later guesses. The situation is different if we do use such information. In fact, if we choose “stank” as our 3rd guess then there are 3 possible resulting patterns: “GGGGG”, “GGG*G”, or “GGG**”. If “GGGGG”, then “stank” is the target and we win in 3 tries. If “GGG*G”, then “stack” is the target and we win in 4 tries. If “GGG**”, then the target is “stamp” or “stash”, in which case we have a 50-50 chance of winning in 4 tries; if not we win in 5 tries. Thus, we have a 13/14 chance of winning within 4 tries and we will always win within 5 tries.

Reference

New York Times (2022) Wordle
https://www.nytimes.com/games/wordle/index.html

Leave a Comment