GenerateRandomSearch

Nurimeizu Puzzle Generator

Nurimeizu is a shading puzzle in which the shading builds a maze. The grid is cut into rooms; you paint whole rooms so that the white cells form one maze with no loop, running from S to G past every circle and away from every triangle, without any 2 × 2 square all painted or all white. This makes fresh puzzles at 6, 7 or 8 squares a side, each with a single answer proved by a search from the printed puzzle alone, and prints the puzzle and its answer in black and white.

What this generator does

Cuts a grid into rooms of one to four cells, draws a valid maze for those rooms, places S and G far apart along it, and adds circles and triangles only until the puzzle has one answer. The maze generator draws mazes to walk; this is a deduction puzzle whose answer is a maze.

How to use this tool

  1. Choose the grid size and press Make a puzzle. Add a puzzle code if you want to be able to make the same puzzle again.
  2. Solve on screen with paper beside you, or print the puzzle and answer pages.
  3. Press Show the answer to check: painted rooms are dark and the way from S to G is dotted.

Understanding the controls

Grid
6, 7 or 8 squares a side. Larger grids have more rooms and usually need a few more circles and triangles to have one answer.
Puzzle code
Leave empty for a new puzzle from the browser's secure generator. With a code, the same code and size make the same puzzle again; the code is a seed, not a secret.

Worked examples

Code garden, 7 × 7
21 rooms; S and G alone are enough for one answer, with no circles or triangles. 21 cells painted and a way of 19 cells from S to G.
Code garden, 8 × 8
29 rooms, one circle and no triangles; 28 cells painted and a way of 20 cells from S to G.

Common use cases

  • A daily logic puzzle a step beyond Nurikabe
  • A printed puzzle sheet with its answer on the next page
  • Puzzle clubs and classrooms working the same puzzle from a shared code

How this generator works

Rooms are grown from random starting cells to one to four cells each. A search then decides each room — painted or white — in reading order, abandoning a branch as soon as it completes a 2 × 2 square of one colour, closes a loop of white cells, or seals off a group of white cells while others exist elsewhere; run once with a shuffled order it draws one genuine answer. S and G go on two white cells as far apart along the maze as possible. The same search, now counting answers from the rooms and marks alone, looks for a second answer; while one exists, a mark is added from a cell where the two differ — a circle on this answer's route that the other avoids, or a triangle on a white cell off this route that the other uses. Every search has a step limit: one that reaches it proves nothing, so that layout is thrown away. Afterwards the answer is read again cell by cell against every rule, and the count is run once more from the printed puzzle; a count stopped by the limit is reported as not decided, never as a pass.

Randomness and fairness

Rooms, the drawn maze and the choice of marks come from a random sequence: the browser's secure generator, or a seeded one when you give a code. A code repeats a puzzle while the generator is unchanged. Codes are deterministic, not cryptographic.

For how randomness is produced across the whole site, see how Generate Random works.

Assumptions this tool makes

  • Nikoli's published rules for Nurimeizu, restated in the instructions on the page.
  • Marks sit in rooms that stay white, so a circle or triangle is always on a white cell.

Limitations and good to know

  • Square grids of 6 to 8 only; larger grids are not offered because proving one answer takes too long in a browser.
  • Difficulty is not graded: puzzles are as hard as their layout makes them.
  • Rooms are generated, not hand-designed, so they lack the deliberate themes of magazine puzzles.

Common mistakes

Painting part of a room
Rooms are painted whole or not at all. Decide room by room, not cell by cell.
Forgetting the 2 × 2 rule for white cells
A 2 × 2 block of white cells is as wrong as a painted one, and it always makes a loop too.
Taking any path from S to G
Because the white cells have no loop there is exactly one way from S to G; the circles must be on it and the triangles off it.

Practical tips

  • Start with rooms next to marks: they are white, and their neighbours often follow from the 2 × 2 rule.
  • A white cell with only one white neighbour is a dead end of the maze; S and G are often at dead ends.
  • Print the puzzle at a large size and pencil in rooms you are sure of.

Privacy and your data

Puzzles are made in your browser. With analytics consent, usage counts record that a puzzle was made or failed; the rooms, marks, answer and any puzzle code are never sent.