Sudoku, the Process from Puzzle to Game

Sudoku was the first game I built for Cliko. I had solved it for years, first in newspapers, then in puzzle books, and only much later online. It was a proof of concept: if people came back to a sudoku every day, they would come back to harder things too. They did.

📖 Guide· Mohammed Tauheed

Sudoku, the Process from Puzzle to Game

Sudoku was the first game I built for Cliko. It was also the first one I had to rebuild, because 22 of its puzzles were quietly cheating.

Variant Sudoku, Kakuro and Calcudoku ZAP on Cliko Games

The first game, and the first rebuild

Sudoku was the first game I built for Cliko. I had solved it for years, first in newspapers, then in puzzle books, and only much later online. It was a proof of concept: if people came back to a sudoku every day, they would come back to harder things too. They did.

Later I tested it properly and did not like what I found. Out of 210 boards, 22 could not be finished by logic. At some point you had to guess a number and see if it worked. Every one of them had exactly one answer, so on paper they were valid.

But a sudoku that makes you guess is a coin toss with extra steps, and I had been serving them to people as puzzles.

What a paper puzzle does not have to do

A newspaper sudoku has it easy. Somebody makes it once, checks it once, and prints it. Nobody asks it for a fresh grid at midnight, or for an easier one because the last was too hard.

A game has to do all of that on demand, inside a browser, in about the time it takes you to blink. So the puzzle stops being a page and becomes a machine that makes pages, and every promise a puzzle book makes has to be kept by that machine, every time, for every player.

What we changed

The fix was to stop judging difficulty by how many numbers are given and start judging it by what a person has to think. The new generator builds a grid, proves it has one solution, and then solves it the way you would, one technique at a time, before it accepts it. On the next 126 boards the number that needed a guess was zero. Easy boards stopped being a matter of filling in the obvious squares, and Medium and Hard started asking for a second level of technique instead of just more patience.

Online, the daily challenge always runs at Medium, so the whole world is solving the same fair board that day. There is a hint button, and it fills one correct square, but it adds thirty seconds to your time. I wanted help to be there when you need it and to cost just enough that you try one more scan first.

From one puzzle to eight

Once the engine could prove and rate a board, adding variants became a matter of adding rules. Variant Sudoku now has eight: Classic, Diagonal X, Jigsaw, Windoku, Anti-Knight, Even/Odd, Thermo and Killer, at seven difficulty levels from Beginner to Cyborg.

Each variant is the classic puzzle plus one idea, and the whole difficulty of a variant lives in that one idea. Diagonal X asks both long diagonals to hold 1 to 9. Jigsaw replaces the neat boxes with nine irregular shapes. Anti-Knight forbids the same digit a chess knight's move apart, which sounds simple until you count: there are 224 knight connections on a 9 by 9 board. We draw only the ones that matter to the square you are looking at, so the board never gets buried under all of them at once.

Advertisement

The variant that was too easy, and the one that would not build

Diagonal X surprised me. The extra rule adds so many deductions that a board clued like a normal Medium collapses into something trivial. So a Diagonal grid has to start with fewer numbers than a Classic grid of the same level, or it is not the same level at all.

Jigsaw was harder for a different reason: my own generator could not make the shapes. To build irregular regions it starts from the neat boxes and swaps squares between neighbouring regions. In 8,800 attempts it accepted none. It took a while to see why. It was always swapping a square with the square right next to it, and that move cuts a region in two every single time. Choosing the two squares independently fixed it. (I still think about that bug when I play a Jigsaw grid.)

Why Killer has fewer levels

Not every variant offers every level, and Killer is the reason. Its harder grids generate correctly, but in testing some of them took between two and a half and almost six seconds to build. In a browser, a pause that long feels like the game has frozen. We could have lowered our standards for a "hard" Killer, or let you wait. We did neither. Killer offers the levels it can build quickly and well, and a request for a level it cannot deliver is served from one it can, the same way for every player. A smaller menu of honest puzzles beats a long menu with a few fakes in it.

Paper does not move. Phones do.

The last step from puzzle to game was the one I underestimated most: a phone screen is not a page. It changes size while you hold it.

I play on my iPhone, and that is where the bugs showed themselves. The number pad would sit in one long row, then jump to two rows after a scroll, because the browser's toolbars slid away and the game re-measured the screen. We fixed the pad at two rows, always. A board dealt while Chrome's bars were hidden kept that larger size when they came back, and pushed the pad off the bottom. Pinching to zoom made the board redraw itself out of shape, because Safari reports the zoomed area as if it were the whole screen.

None of these exist on paper. All of them are fixed now, and each one taught the same lesson: a grid on a phone has to stay exactly where your thumb expects it, whatever the browser does around it.

How to open a Diagonal or Jigsaw grid

Both variants reward one habit: read the extra rule before you read the numbers.

On a Diagonal X grid, start where the diagonals cross the boxes. The centre square sits on both diagonals, its row, its column and its box at once, so it is the most constrained square on the board and often the first to fall. After that, each diagonal is just one more line that must hold 1 to 9, and a number missing from a diagonal can usually only go in one or two places along it.

On a Jigsaw grid the trick is a counting rule solvers call the law of leftovers. Any three whole rows contain each digit exactly three times. Mark those three rows, then look at the jigsaw pieces that poke out of them and the pieces that poke in. The squares sticking out must hold exactly the same set of digits as the squares sticking in. It sounds like magic the first time it works, and after that you look for it on every page.

Older than its name

Sudoku is younger than most people think, and older than its name. The modern puzzle first appeared in 1979 in an American puzzle magazine from Dell, under the plain title Number Place, and it took a Japanese publisher to give it the name it travels under today. It went global in 2004, when The Times in London started printing it.

And forty-odd years after Number Place, the same nine rows and nine columns are still teaching people like me something new each time we try to put them on a different kind of screen. Try all eight variants free in Variant Sudoku. When you want a change of numbers, Kakuro is the sudoku player's natural next step, and our post on how we made the puzzle books tells the story of the sudoku that went back to paper.

▶ Play Free on Cliko Games
Advertisement
Guides & articles16 guides · new posts every week