# Neighbors Grid Puzzle: A Puzzling SE

This is an entry for Fortnightly Topic Challenge #44: Introduce a new grid deduction genre to the community.

Here is a standard Neighbors puzzle.

Rules of Neighbors:

1. Place one of the digits 1, 2, or 3 into each cell, one digit per cell, so that each digit appears the same number of times in each row and column.
2. After placing all digits, each white cell must touch at least one cell with the same number along an edge, and each gray cell must not touch any cells with the same number along an edge.

• I'm really amazed at the pace you're producing such quality puzzles! Commented Dec 10, 2020 at 8:00
• @Bubbler ah thank you, I might go with "I have too much free time now, how should I do to be productive" instead.. Commented Dec 10, 2020 at 15:33
• Some afterwords: I actually want to put P on top-left part but scrapped it later on. Also, the puzzle is still solvable without the clue "1" in the top center, but that will make the break-in much harder, no? :) Commented Dec 10, 2020 at 15:35

First, fill in the center three columns.

White dead-end cells must share the number with the adjacent white one. So R1-2C6 are 3, and R8-9C6 can't be either 2 (adjacent gray 2) or 3 (too many on that column) so they're 1. Now we need to place three 2's on that column, but if any of them are adjacent they must be white (giving 2+ white cells), a contradiction. So the 2's are spaced like this.

On C5, R3/5/7/8 cannot be 2 because they're adjacent to gray 2, and R4 cannot be 2 because then it must escape to the right, but it can't due to gray 2 again. So the remaining two 2's go to R2C5 and R6C5. Escape and fill in the dead ends.

C5 has two 1's and three 3's remaining, none of which can be adjacent to the same number. So the top 3 (R3-5C5) must be 3-1-3. 2's are used up on C4 too, so we fill in R3-5C4 using gray adjacency. R8-9C4 must have the same numbers, so they're 3. Fill in the rest of C5 using grays.

Then here comes an important deduction:

Focus on the white pairs R6C8-9, R8C8-9, and two grays between them. If R6C8-9 = X, R7C8 and R7C9 must be something different from X and they must be different from each other. So they must be Y and Z respectively (where X, Y, Z are all different). Then R8C8-9 are forced to be X. Now, R6C8-9 can't be 2 and R8C8-9 can't be 1, so X = 3.

The left side of R8 can't be 2-2-1 because 1 can't escape up, and 1-2-2 either because one of the grays below must be 2. So they're 2-1-2. Also, R6C1-2 must be 1.

If R6C3 is 2, the remaining numbers on C3 are 11333, and R4C3 is forced to be 1, which cannot escape in any ways. So R6C3 must be 1. Also, R1-2C8 are 1 (no other numbers possible), and R7C7 is 3 (no other choice for 3 on R7).

In order to place three 3's on C3, R3 and R5 are mandatory, and the other one goes to either R1 or R2. Since R4C3 can't be 1, it must be 2, escaping left. Fill in R5C1, and the remaining numbers on R5 are 112, which can be used in only one way to fill three grays in a row.

The rest is just basic deduction. The answer is:

• Yup, this is correct, very well done! :) Commented Dec 10, 2020 at 15:36