Generate Sudoku Puzzle
generate_sudoku_puzzleCreate a uniquely-solvable Sudoku puzzle at your chosen difficulty, from very easy to very hard. Ensures a valid puzzle with exactly one solution for practice or testing.
Instructions
Generate a new, uniquely-solvable Sudoku puzzle at the given difficulty.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| difficulty | No | medium |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| givens | Yes | Actual number of filled cells in the generated puzzle | |
| puzzle | Yes | A 9x9 Sudoku grid; 0 marks an empty cell. | |
| difficulty | Yes |