gekro
GitHub LinkedIn

Sum Grid

Play a free number-crossword in three sizes: fill white squares with digits 1 to 9 so every run adds up to its total, with notes, hints and one solution.

Time 0:00

Filled 0 of 0

Your best -

  • Dark square: the amber number in the top right is the total for the run to its right, the blue number in the bottom left is the total for the run below
  • Digit given in the puzzle: bold with a thick border
  • Breaks a rule: a dashed red border and a mark
  • Hint: a dashed amber border and a diamond

Pick a white square, then a number. Digits in one run must all be different and must add up to its total. Arrow keys move between white squares, 1 to 9 fill, 0 or Backspace erases, N switches pencil notes, U undoes, H gives a hint. A tick appears beside a total when its run is complete and right. A best time only counts if you did not use a hint.

How the puzzles are made

A pattern of white and dark squares is drawn at random and tidied so that every white square sits in an across run and a down run, each at least 2 squares long, and all the white squares join up. Digits that differ within every run are filled in, and the totals are just their sums.

Then a solver counts the answers. If there is more than one, a square where two answers differ is copied into the puzzle as a given digit, and the count is repeated until there is exactly one. Hard then tries to take givens away again, keeping only those the puzzle needs. Easy keeps a quarter of the white squares as givens.

Hints use the totals. A run of 2 squares adding to 3 can only be 1 and 2, and a run of 3 adding to 24 can only be 7, 8 and 9. If the other squares in a run are filled, the last one is a subtraction.

As-is, no warranty. These apps are free under their listed license and run entirely in your browser. Use at your own risk — don't blame me if your PC catches fire, your dog runs away, or the math turns out wrong. Verify anything that actually matters. None of this is professional financial, medical, legal, or engineering advice.

© 2026 Rohit Burani · MIT · Built at gekro.com · View source ↗

Guide

How to play

The board has dark squares and white squares. A dark square can carry up to two numbers. The amber number in its top right is the total for the run of white squares going across, starting just to its right. The blue number in its bottom left is the total for the run going down, starting just below it. A diagonal line splits the two.

Fill every white square with a digit from 1 to 9 so that:

  1. the digits in each run add up to that run’s total, and
  2. no digit appears twice in the same run. A digit may repeat in different runs.

For example, 2 squares with total 3 can only hold 1 and 2, and 3 squares with total 24 can only hold 7, 8 and 9.

Pick a size (5x5, 7x7 or 9x9, counting the dark first row and column) and a level (Easy, Medium or Hard). New puzzle deals a fresh one, Restart resets this one, and the page address carries the seed so you can send a friend the exact puzzle.

Controls:

  • Tap a white square, then a number on the pad; tapping the same number clears it. The two runs through the selected square are tinted, amber for across and blue for down.
  • Notes switches the pad to pencil marks. Placing a digit removes it from the notes in the same runs.
  • Erase clears the square and Undo takes back the last change. On the keyboard, arrow keys move between white squares, 1 to 9 fill, 0 or Backspace erases, N switches notes, U undoes and H asks for a hint.
  • Show mistakes is on to start with. A square that repeats a digit in a run, or sits in a run over its total or full and wrong, gets a dashed red border and a mark.
  • Check marks wrong digits with a solid red border and a cross.
  • Hint fills in one square and tells you why, or says so if one of your digits is wrong. A puzzle where you used a hint does not count toward your best time, even after a restart.

A tick appears beside a total when its run is full and right. Colour never works alone: the two totals differ by position and a diagonal, given digits are bold with a thick border, rule breaks have a dashed border and a mark, and hints have a diamond. Screen readers hear each square’s position, digit or notes, and the totals of its two runs. Nothing flashes, and the win animation is off under reduced motion.

How it works

Making a puzzle with one answer

  1. Pattern. Row 0 and column 0 are dark. Inside, squares are made dark at random and the pattern is tidied: a lone white square in a run of 1 turns dark, runs longer than the level allows are cut, and only the largest connected white piece is kept. Easy allows runs of up to 4, Medium up to 6 and Hard has no cap.
  2. Digits. The white squares are filled with digits that differ within every run, by a backtracking search that tries digits in random order.
  3. One answer. A solver counts the solutions, stopping at two. If there are two, the page picks a square where a second solution differs from the intended answer and copies the correct digit in as a given. It repeats until there is exactly one solution.
  4. Level. Easy then adds givens until a quarter of the white squares have one. Medium keeps only the givens it needed. Hard tries to remove each given again and keeps only those whose removal brings back a second solution.

Given digits over seeds 1 to 20:

Level5x57x79x9
Easy2 to 73 to 55 to 9
Medium1 to 75 to 148 to 12
Hard2 to 65 to 137 to 22

The solver

For each run the solver knows every set of different digits that can make its total. There are 511 non-empty subsets of 1 to 9, each filed by its size and its sum. A run keeps only digits that appear in some set that still fits what each square can be. A square down to one digit is removed from the rest of its run. The two runs through a square pass what they learn to each other until nothing changes, and then the solver tries each digit of the square with the fewest options.

Hints

When the other squares in a run are full, the last one is a subtraction, and the hint says so. When a total allows only one set of digits, it names the set. Otherwise it says that the across and down runs together leave one choice, or, failing that, reveals a square.

What the tests check

  • The digit-set table against all 511 subsets of 1 to 9, and the run geometry against an independently written scan.
  • The solver’s count of solutions against an independent counter that checks each run by brute force. They agree on hand-made boards (one answer, two answers, none) and on over a hundred generated boards with givens removed or a total nudged.
  • Every generated puzzle has exactly one solution by the independent counter, totals that equal the sums of the stored answer, one connected white piece, and runs within the level’s length cap. In a Hard puzzle, taking away any single given gives more than one solution.
  • A hint is always the right digit for an empty square, and following hints from a fresh puzzle fills in the whole answer.

Privacy and storage

Nothing is uploaded and there is no account. Your best time for each size and level is saved in your browser’s local storage as small whole numbers in a small JSON object, and anything read back is checked before use. The only other state is the page address.

Limits

  • Boards stop at 9x9, so the longest run is 8 squares.
  • The score is time, which starts on your first change and pauses when the tab is hidden.
  • On a 9x9 board pencil notes are small. They are easier to read on a wider screen.
  • Levels describe the pattern and the given digits, not how deep the reasoning is.

Everything runs locally in your browser.

All Fun tools →

For informational purposes only. Not financial, medical, or legal advice. You are solely responsible for how you use these tools.