{
  "id": 4160893,
  "title": "Nine puzzle solvers, one browser tab, zero servers: a tour of classic search algorithms",
  "url": "https://urgent.news/2026/08/29/nine-puzzle-solvers-one-browser-tab-zero-servers-a-tour-of-classic",
  "topic": "tech",
  "section": "Tech",
  "published": "2026-08-29T09:51:53.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/lucian_lkb_1f009d/nine-puzzle-solvers-one-browser-tab-zero-servers-a-tour-of-classic-search-algorithms-4g87"
  },
  "original_language": "en",
  "account": "Nine puzzle solvers exist in a single browser tab, running without any servers. These solvers showcase classic algorithms, such as constraint propagation, adversarial search, heuristic search, brute-force scanning, and pattern matching.\n\nThe first group consists of constraint propagation algorithms, which include solving Sudoku puzzles. In Sudoku, a single value can force other cells' values, gradually narrowing down the options. This method works for easy and medium boards (naked and hidden singles), but harder puzzles may require a backtracking search. The same engine used to solve the board can also provide hints and verify the uniqueness of a puzzle.\n\nThe second group is adversarial search, encompassing minimax, negamax, and alpha–beta pruning techniques. This algorithm is used for two-player games, such as Minesweeper, Connect 4, and Chess. In Minesweeper, each revealed number constrains the hidden mines, allowing the solver to deduce safe and mine cells with exact probabilities.\n\nConnect 4 employs the same algorithm, but representation is crucial due to the larger game tree. By using bitboards and bit shifts, win detection becomes faster. In Chess, negamax with alpha–beta pruning and a hand-written evaluation function allows the solver to reach a club-level performance.\n\nThe third group revolves around heuristic and shortest-path search algorithms. For mazes, breadth-first search (BFS) is the ideal shortest-path algorithm. BFS explores the grid in rings outward from the start, ensuring the first time it reaches the goal, it's done through the shortest route.\n\nThe final group focuses on the 15-puzzle, where plain BFS would be impractical due to the enormous state space. Iterative-deepening A* (IDA*) with an admissible heuristic, specifically Manhattan distance and linear-conflict, solves the 15-puzzle. Adjusting the heuristic to a weighted IDA* balances optimality and speed, delivering near-optimal solutions for hard scrambles in milliseconds.",
  "summary": "I recently finished building a small suite of puzzle and game solvers that all run entirely in the browser — no backend, no API calls, no machine-learning models. You paste in a Sudoku, a chess position, or a crossword pattern, and the answer comes back instantly, computed on your own device. The fun part wasn't the UI. It was that each puzzle turned out to be a textbook excuse to reach for a…",
  "key_points": [
    "Nine puzzle solvers run in a single browser tab without servers",
    "Solvers demonstrate solving Sudoku, adversarial games, maze navigation, and the 15-puzzle"
  ],
  "editors_take": null,
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}