fludoku library
Generates and solves Sudoku puzzles with dimensions 4, 9 (default), 16, or 25.
Classes
- Board
- A board that can be a Sudoku Puzzle (with only one possible solution) or not. Any non-zero value in the set of initial values for the board becomes a read-only position, and as such, cannot be modified.
Enums
Functions
-
findSolutions(
Board puzzle, {FindSolutionsProgress? progressCallback, int maxSolutions = 1, TimeoutTracker? tracker}) → List< Board> -
Finds solution(s) for a given
puzzleboard withintimeoutMillisinterval that defaults to one day. -
generateSudokuPuzzle(
{PuzzleDifficulty level = PuzzleDifficulty.medium, int dimension = 9, int timeoutSecs = 15, GeneratorProgress? onProgress}) → (Board?, String?) - Generates a new Sudoku puzzle with the specified difficulty level and dimensions. A Sudoku board is a puzzle when it is guaranteed to have only one solution.
Typedefs
- FindSolutionsProgress = void Function(int progress)
-
Callback type for Solver to report its progress searching for solutions.
progressis expected to be an integer between 0 and 100. - GeneratorProgress = void Function({int current, int total})