generateGridWithGivens
Generates a Sudoku grid with the given cells filled in based on the puzzle configuration.
Example:
val puzzle = SudokuPuzzle(
difficulty = Difficulty.MEDIUM,
type = SudokuType.Sudoku9x9,
seed = createSeed(123L),
givens = listOf(Givens(0, 0, 5), Givens(1, 1, 3)),
solution = ... // provide the solution grid here
)
val grid = puzzle.generateGridWithGivens()
// grid[0][0] will be 5, grid[1][1] will be 3, and the rest will be 0
Content copied to clipboard
Return
A list of lists representing the grid, where each inner list corresponds to a row, and each element in the inner list corresponds to a cell value.