SudokuSchema
Creates a new SudokuSchema instance with the specified puzzle, solution, difficulty, and Sudoku type.
This function provides a convenient way to instantiate a SudokuSchema, which encapsulates the core components of a Sudoku puzzle. It converts the provided puzzle and solution strings into their respective SudokuString representations before constructing the SudokuSchema.
Example:
val schema = SudokuSchema(
puzzle = "123456789",
solution = "987654321",
difficulty = Difficulty.MEDIUM,
sudokuType = SudokuType.Sudoku9x9
)
Return
A new SudokuSchema instance with the specified properties.
Parameters
The initial puzzle layout as a string, representing the state of the Sudoku grid with some pre-filled cells.
The solution layout as a string, representing the completed Sudoku grid that solves the puzzle.
The difficulty level of the Sudoku puzzle, used to categorize the puzzle's complexity.
The type of the Sudoku puzzle, which defines the grid size and other characteristics (e.g., 9x9 classic Sudoku).