A sudoku puzzle is usually made by building the answer board first and then erasing digits. The NumberPlace app also makes its puzzles on the spot this way every time. Here are the steps.

1. Make a Completed Board

First, make one completed board that follows the rules. Starting from the top-left square, pick one digit that can go in and put it in, square by square. If you reach a square where no digit can go in, go back to the previous square and try a different digit (you search while stepping back, so it’s called backtracking).

In the app, the order of digits to try is shuffled for each square, so you get a different board every time.

112233445566778899349567182516842793872391645185239476724615839693478521458123967931786254267954318

2. Erase Digits Symmetrically

Next, erase digits. In the app, two squares facing each other across the center of the board are erased as a pair. So the layout of digits in the finished puzzle looks the same when you turn the board 180 degrees (point symmetry).

112233445566778899351822982914529672418396485512973726748

The puzzle above is a ★1 puzzle made from the previous board. You can see that the layout of squares with digits is point-symmetric. Making it point-symmetric makes it look tidy, and it has long been considered the proper look for a sudoku puzzle.

3. After Each Erase, Check “Can It Be Solved with Techniques?”

If you just erase, you can end up with two or more solutions. So each time it erases two squares, the app checks whether the remaining digits can be solved all the way with techniques alone. If not, it puts those two squares back and moves on to the next pair.

Every technique advances using only things you can say for certain: “only this digit fits here” or “this digit can’t go here”. If a puzzle can be solved all the way with techniques alone, there can be no other answer. In other words, a puzzle that can be solved with techniques has one solution (Why a Sudoku Has Only One Solution).

4. Match the Star Difficulty

The star difficulty is set by the hardest technique needed to solve it. For each star level, the app sets an upper limit on the techniques it may use, and keeps erasing digits as long as the puzzle can be solved with those techniques alone.

  • ★1 uses only “only this square can hold it”, ★2 goes up to “only this digit fits”, ★3 goes up to locked candidates and pairs, and ★4 and ★5 use advanced techniques such as the X-Wing and XY-Wing.
  • For ★1 and ★2, it stops erasing when the starting digits are down to the target count. If you erase as much as you can, it gets too hard.
  • If the finished puzzle doesn’t meet the star’s conditions (the techniques needed and the number of starting digits), the app makes it again from a new completed board.

Made the usual way, puzzles that need advanced techniques rarely come out (The Hardest Sudoku in the World). So for ★5 puzzles, the app remakes up to 500 times until the conditions are met. Even so, it takes about 0.13 seconds on average on a computer. On a phone it can take longer, so the app makes the next puzzle in the background while you play and keeps it ready.

If You Make Your Own

When you make a puzzle with paper and pencil, you’ll fail less if you go like this.

  1. Write a completed board (it’s easy if you take the answer of an existing puzzle and rename its digits).
  2. Erase digits a little at a time.
  3. After each erase, try solving it yourself and check that you can get all the way through using only squares you have a reason for.
  4. If you reach a place that needs a guess, put back the digit you erased last.

Just renaming the digits (for example, swapping every 1 and 2) already gives you a puzzle that looks different.