Codebreaker Master

Strategy in Codebreaker Master

In brief

Each clue eliminates codes. After each guess, keep in mind the codes that are still possible: those that would have given exactly the same clues for all your guesses. Then choose a guess that best splits these codes, and preferably play a code that could still be the right one.

Reasoning by elimination

At the Intermediate level, there are 6,720 possible codes at the start. A code remains possible as long as it would have given, for each of your guesses, exactly the clues the app displayed. In this level's sample game, 1,920, 464, 32, 7 and 1 remain after each guess: the last guess is the code.

  • 3 misplaced: 1,920 codes remain possible.
  • 3 misplaced: 464 codes remain possible.
  • 2 correctly placed, 1 misplaced: 32 codes remain possible.
  • 2 correctly placed, 1 misplaced: 7 codes remain possible.
  • 5 correctly placed: 1 code remains possible.

The first guess

A good first guess splits the codes into many small groups, one group per possible response. The table shows, for a few first guesses, the number of responses the app can give and the number of codes that remain in the worst case.

Intermediate level, 6,720 possible codes at the start.
First guessPossible responsesCodes remaining, worst case
171 920
101 680
62 880

At the Intermediate level, where the code never repeats a color, the guess with 5 different colors (red, yellow, blue, orange, purple) leaves at worst 1,920 codes and allows 17 responses. The guess red, red, yellow, yellow, blue, which repeats two colors, allows fewer responses (10) but leaves only 1,680 codes at worst: repeating a color in a guess can pay off, even when the code repeats none. A row with empty slots separates the codes much less well.

Playing a code that is still possible

When few codes remain, play one of them if you can: either it is the right one and you win, or the response eliminates the others. In the sample game at the Hard level, before guess 6, 2 codes remain; the guess purple, gray, yellow, orange, black, yellow is one of them, and each of the 2 codes would give a different response. After the response, only 1 code remains: the next guess wins.

When the code can repeat a color

At the Hard and Extreme levels, a color can appear more than once in the code. The best first guess then changes:

Hard level, 430,920 possible codes at the start.
First guessPossible responsesCodes remaining, worst case
2794 620
2773 440
1584 420
6185 220

At the Hard level, the guess red, red, yellow, yellow, blue, blue leaves at worst 73,440 codes, versus 94,620 for red, yellow, blue, orange, purple, green. Also keep in mind that a color you've found may appear several times: a correctly placed peg doesn't mean its color is used up.

Incomplete rows

The app accepts an incomplete row, except for the last one. It can't win and it uses up a row: at the start, it teaches less than a complete row (6 possible responses for red, yellow, empty slot, empty slot, empty slot, versus 17 for red, yellow, blue, orange, purple). It can be useful when only one specific question remains to be settled, for example the position of a single color.

In Last Chance

The rows already played may be enough to leave just one code. Go through them one by one, each time keeping only the compatible codes. In the site's example, at the Intermediate level, the 9 pre-filled rows leave only a single code.