Rules of Fillomino:

  • Fill in all empty cells with numbers under the following rules.
  • Divide all of the board into blocks.
  • Fill each block with the same number horizontally or vertically.
  • Each block contains as many cells as the number in the block.
  • Same sized blocks cannot touch each other, horizontally or vertically.

Non-consecutive variant rule:

  • Two horizontally or vertically adjacent cells cannot contain two consecutive numbers.

Anti-knight variant rule:

  • A cell cannot contain the same number as any cell that is a knight's move away from it. This rule applies even if the two cells belong to different blocks.

How many solutions does the following puzzle have?


2 Answers 2


I've found out that it is not in anyone's interest to post excessive screenshots, so draw a grid yourself to follow my deductions.

The number of solutions is



Consider a block that is not a straight line, and numbered 5. Then there exists a cell in the block such that at least one of each of horizontally adjacent and vertically adjacent cells is in the block. By anti-knight we can eliminate some cells from having 5, those are denoted by red. If the orange cell contains 5, then both green cells cannot contain 5 also by Anti-knight. However, the block only has size 4, which does not work. Hence, both the green cells contain 5.Figure 1 From this, we can also clearly see a block with size at least 6 is impossible since the board is too small.

We now split into cases by

The ways to make a block for the center 5

Case 1:

Figure 2 And rotated 90 degrees Any cell on column B or column D must not be a 2, because this will result in a cell on that column, not in any blocks yet, adjacent both to 2 and 5. That means that cell cannot have any number from 1,2,3,4,5 from the rules, which is absurd. By non-consecutive we must not have 4 in column B or column D, so those columns must consist of 1 or 3. Now consider cell D3. If it is 1, then both D2 and D4 are 3. By anti-knight E2 and E4 are not 3, so we must have D1, E1, D5, E5 containing 3. Figure 3 E3 cannot be 1 or 2 since its adjancet to D3, cannot be 4 or above since the remaining region has only size 3, and cannot be 3 since its neighbours can't be 3. So we conclude that D3 cannot be 1. It remains to check the case when D3 is 3. By anti-knight B2 and B4 are not 3 so they are 1. Hence B3 is not 1, which means B3 is 3. Then again by anti-knight D2 and D4 are not 3 so they must be 1. Finally, by anti-knight B1, B5, D1, D5 are not 3 so they are 1.Figure 4 It is clear that the current 3s cannot be connected to each other, but there are not enough space for each of them to have a block of size 3. Hence we have shown that there are no solutions in this case.

Case 2:

Figure 4 Each of B2, B4, D2, D4 cannot be 4 or 5. If any of them are 2, there will be a cell that is not currently in a block that is adjacent to both 2 and 5, which means we cannot fill in a number in it. Hence, B2, B4, D2, D4 only consists of 1 or 3. We now consider the case where all of them are 3. Then A2, A4, B1, B5, D1, D5, E2, E4 cannot be 3 by anti-knight, but then all of B2, B4, D2, D4 cannot extend their regions. So at least one of them are 1. Since there is symmetry, assume B2 is 1. All of A3, C1, C5, E3 cannot be 4 or 5, and so the remaining unfilled cells do not have a large enough size to form a 4 or 5 block. Combined with non-consecutive, A2, A4, B1, B5, D1, D5, E2, E4 can only be 3. By anti-knight, A3, C1, C5, E3 cannot be 3 and does not have enough space to put a 2, so they must be 1. Hence we must fill A1, A5, E1, E5 with 3, yielding the following solution: Figure 6

Case 3:

Figure 7 And rotated 90, 180 or 270 degrees We start from D5. It cannot be 4 or 5. If it is 2, E5 is 2, and we cannot fill E4. If it is 1, then we easily get E3, E4, E5 are 3, and D3 is 1. Using the rules we can uniquely determine that D2 is 4. B1 (anti-knight), C2 (non-consecutive), E2 (non-consecutive) cannot be 4, so C2, D2, E2 must be 4 to form a region. If C2 is 2, B2 is 2 but then we cannot fill B3, so C2 is 1. B2 is then 3, so B1 is 1. A2 cannot be 2,3,4 or 5, so it must be 1. A1 is excluded from the rest of the grid, so it must have 1, but its adjacent cells forbids it to have 1. Hence we conclude that D5 cannot be 1, and so it is 3. Similarly, B5 is 3. We can then fill A4, A5, E4, E5 with 3. B3 and D3 can only be 1 or 2. So A3 and E3 cannot be 1. Eliminating the possibilities of them being 2,3,4,5, there are no way to fill A3 and E3, hence we conclude that there are no solutions for this case.

In conclusion,

There is only 1 solution, presented in Case 2.

  • $\begingroup$ Nice solution, but your last case can terminate sooner, as A3/E3 cannot be 4 (adjacent 3 in A4/E4). $\endgroup$
    – fljx
    Commented Jun 18 at 10:52
  • $\begingroup$ @fljx thanks, I fixed that in my solution $\endgroup$ Commented Jun 18 at 12:01

The possible blocks are severely restricted by the anti-knight rule. Only eight kinds of blocks satisfy it and fit inside the provided grid:
* The monomino
* The domino
* Both trominoes
* The I-, T- and O-tetrominoes
* The I- and X-pentominoes

Suppose the central given is occupied by an I-pentomino, then the latter can only fit in one way – up to symmetry, let's say C1 to C5 – which splits the rest of the grid into two 5×2 regions. Look at the upper region from A1 to B5. It is easy to see that no pentomino fits without violating the rules, and if a tetromino fits it must be an I from (again WLOG) A1 to A4. But then the block containing B1 must be either a monomino or domino, and then there are no valid options for the block covering B2 or B3 respectively. In the sequel we will refer to such cells has having no options.

So only monominoes, dominoes and trominoes fill the two regions. The non-consecutive rule rules out dominoes (they would have to touch the other two block types), so each region has 1/3 or 4/2 monominoes/trominoes respectively. In either case it is easy to prove that there are no valid fillings.

Now suppose an X-pentomino centred on C2, i.e. offset, occupies the given. The block containing B1 cannot be a pentomino or tetromino by non-consecutive; if it is a domino then A2 has no options; if it is a tromino then a monomino is forced at A3 and B3 has no options.

Thus B1 is a monomino. Non-consecutive rules out anything but a straight tromino covering A1 and in turn B3 is forced to a monomino. This fixes the first three columns.

B4 and D4 now have to belong to tetrominoes, but no tetromino can cover both without also touching the X-pentomino. The only way to fit two tetrominoes into the remaining space (by fillomino rules alone) is two Os, but this violates the anti-knight rule.

We finally obtain that the block covering the central given must be a centred X-pentomino. By similar reasoning as in the I-pentomino case only monominoes and trominoes can fill the remaining space, and from there it's not too hard to show by casework that this is the unique solution:

  • $\begingroup$ I really like this solution. $\endgroup$
    – HappyDog
    Commented Jun 20 at 11:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.