Back to the blog

edition 7 min read

How to count letter changes in a word ladder

Compare the start and target one position at a time to find a lower bound on moves, then see why some routes need a detour.

Game strategies

Two aligned rows of tiles highlight positions that differ.

Find the minimum number of moves

Before you find an intermediate word, you can work out how many moves the puzzle must take at a minimum. Put the starting word above the target and count the positions that differ. Every move changes only one position. If two positions differ, you need at least two moves. You can solve it in two only if a direct replacement produces a word you can play.

With PONT and FORT, the first and third positions differ, so two moves would be sufficient if you found an intermediate. PORT works. You place the R first and the F next. Once this journey is written, you can say that two is the minimum length. You know a route that reaches the terminal and you know why a shorter route could not change both positions.

PONT → PORT → FORT

This calculation is often called Hamming's distance for words of the same length. To play, the expression “positions différentes” (different positions) is sufficient. The comparison is about the location of the letters. If the same U goes from the second to the third box, there is a difference to be examined on each side. The calculation does not concern the number of letters that could be placed in a bag before redistributed.

When the minimum isn’t reachable

Compare RIME and ROBE. The first R and the last E are common. Two moves still constitute the boundary. If one hopes to achieve this in two moves, it is necessary that the change of the medium form ROME or RIBE. In the lexicon used for this example, no form is allowed. So one must make at least one more move. RIDE then RODE give a trip in three moves. This is a short proof of minimality, because we examined the only two orders that could reach the boundary of two.

RIME → RIDE → RODE → ROBE

To understand the detour, keep a pencil on the third box. M was replaced by a D, then D by B. The switch from I to O occurs while D is in the third position. The change that seemed to be missing in the first move became possible thanks to a letter that the target does not contain. You can recognize the same structure in CARTE around BARBE. The fourth box must be prepared before a B comes to take its place.

CARTE → CARRE → BARRE → BARBE

What if three positions differ?

With three different positions, there are more direct orders. To explore them without repeating the same test, note the first three possible moves on a line. Under each neighbour actually admitted, write the two ways to place the next target letter. Eliminates tests that do not form a word. This approach precisely checks the length three routes. It does not yet say which longer routes is preferred. You can then explore passing neighbours by choosing one of the positions that blocks.

Take PILE and FACE. The last letter is common and the other three differ. FILE is a useful neighbour, because it already places F. If you then count the different positions, it remains the I and L. The following direct transformations do not open the road in the lexicon. Introduce a N provisional gives then FINE. FANE receives the A, then FACE receives the C. Four moves suffice. The number three had a precise utility. It indicated which roads first tested and then allowed to explain the role of the fourth move.

PILE → FILE → FINE → FANE → FACE

Make counting a habit when you play

Before each first move, try to say the number of different positions. This little prediction allows you to compare your real path to a reference. If you solve a riddle in five moves while three positions differed, look for which box has been modified twice. You may also have changed a letter that was correct to then return to its starting value. Finally, see if the last words of the path give a combination of intermediaries that we could have encountered earlier.

For a quick exercise, take LAC and BUS. Note the three differences. Write two first moves that each replace a different letter and look for where they meet. Once the word ladder is found, count the moves without counting the original word. Compare with the terminal you had established. Then add a voluntary detour and ask someone to spot the position that made the extra trip.

Check a route that reaches the minimum

LAC → LAS → BAS → BUS

The three moves successively touch the end, the beginning and the middle of the word. Each place a letter of BUS and the letters placed no longer change. That is enough to ensure that there is no shorter route for this pair.

Count detours after a game

After having solved a string, write the number of the modified box under each arrow. From CARTE, the first move touches the fourth. The second one touches the first one. The last one touches the fourth again. The repetition immediately indicates where the additional move is located. In POMME to POIRE, the first row is identical to the start and the finish but it changes several times during the journey. The same count shows this other type of detour.

You can compare two word ladders that have the same length by following this principle. You may see that they choose a different order for the same boxes or that they use detours at different places. Give both routes to someone who starts and asks them to tell the journey without saying all the words. An explanation like “on a préparé la quatrième lettre, placé la première puis réparé la quatrième” (the fourth letter was prepared, the first letter was placed and the fourth letter was repaired) shows that they understand what justifies the extra move.

Finally, when you hesitate between two solutions, reread the letters that repeat themselves by pointing them instead of following changes in the meaning of words. Word ladders may seem distant while two or three positions carry the essentials of the move.

To your next challenge, keep the number in mind as a point of comparison. Then ask yourself what makes the order of changes possible. That's where the intermediate words make the difference.