Declaration
public static IEnumerable<int[][]> Solve(
int w,
int?[] grid,
bool debugOutput = false
)
Summary
Solves a Numberlink puzzle of the specified size.
Parameters
int | w |
Width of the grid. |
int?[] | grid |
A grid containing the numbers to be linked and null s for the available spaces. The height of the grid
is calculated from the array’s length and w. |
bool | debugOutput |
Determines whether some information is output to the console during solve. |
Returns
Each solution returned is represented as a set of links. Each link is an array of grid locations going from
one digit to its matching partner.