G4G14 Exchange Gift

G4G14 Exchange Gift
Walk a Crooked Path
Solution

Click here to go back to the Walk a Crooked Path puzzle.

First, an important insight:

Any row or section of a row that is blocked on both ends and with an odd number of cells must have at least one non-turn.

This is because every cell with a turn has exactly one horizontal (and one vertical) half-segment inside it, but every horizontal half-segment connects to a partner in the adjacent cell in the same row. If all cells in an odd-length row were turns, one of them would be unconnected.
Of course, the same argument applies to columns, but with 'horizontal' and 'vertical' switched.

Regions

Now, let's analyse the grid. It has 72-3 = 46 cells in it. I've marked various regions in different colors.

The blue cells cannot have turns in them; there are 2 of those (at A3 and A7). There must be at least 1 non-turn in the red cells (A1, A2, B1, B2) because if all four were turns then edge of the board forces their orientation so that they form a tiny loop.

The green column (B4-B6) and the 4 purple columns (C, D, E, F), must each have at least one non-turn, by the "important insight" above.

This gives an upper bound of 46 - (2+1+1+4) = 38 turns. This bound can actually be attained, and to do this each of the 8 coloured regions must contain exactly one non-turn, while the remaining grey cells must all be turns.

Step 1

Column G must contain only turns, and the edge of the board forces their orientation. Excluding the blue cells, the rows 1-6 are all of odd length and hence each contains exactly one non-turn. That accounts for all of them, so the bottom row C7-F7 contains only turns.


Step 2

To avoid forming a small loop, cell F1 is a non-turn, forcing the rest of row 1 and column F to be turns. They can be oriented only one way.


Step 3

To avoid a loop in the red region, cell A2 must be a non-turn, making the rest of row 2 all turns.


Step 4

If cell D6 were a non-turn, then E6 would be too, but we can have only one non-turn on the row. Therefore D6 is a turn. To avoid creating a small loop, it must connect to E6, which is then also a turn.


Step 5

The three grey cells A4-A6 must be all turns, and the green cells B4-B6 must have exactly two turns. If A4-A6 were as shown in the figure, then B6 must be the non-turn to avoid forming a small loop. This leads to the central area of the board becoming inaccessible.


Step 6

Therefore cells A4-A6 must be as shown here, and then B4 must be the non-turn.


Step 7

Cell C6 must be a non-turn, so the rest of column C are all turns.


Step 8 Step 9

All that remains is a 3x2 area in the middle of the board, which has to be filled with 4 turns and 2 non-turns. This can be done in two ways, leading to two solutions with 38 turns.



© Copyright 2022 Jaap Scherphuis, .
Back to Home Page