- Windows/Mac/Linux x86 device.
- git
- zig (0.12.1) https://ziglang.org/download/
- Vulkan compatible graphics driver. (Most modern GPUs are compatible)
- On windows the MSVC / Clang compiler is required.
Ensure you are in the root directory of the project (Where this file is).
First get all dependencies by running the following command:
git submodule update --init --recursivezig build -Doptimize=ReleaseFastYou can choose between running via the zig CLI, or invoking the binary directly. The binary files are generated by build.
zig build -Doptimize=ReleaseFast run
# Or (after build)
./zig-out/bin/Sudoku- Use your mouse and WASD to move around the world.
- Arrow keys to move green "cursor" on board to select input cell.
- Use numbers 1-9 to input numbers into the selected cell.
- Use
Pto solve the current board state. - Use
Nto generate a new good random puzzle - Use
Rto generate a puzzle you can undo. - Use
Cto clear the board. - Use
Zto undo the last move. - Use
Yto redo the last move. - Use
Hto generate one hint you can undo.
Run the CLI
zig build -Doptimize=ReleaseFast run-sudoku
# Or (after build)
./zig-out/bin/sudoku-backendThe Sudoku CLI allows you to run a variety of tests, generate puzzles, solve puzzles from an input format etc.
zig build -Doptimize=ReleaseFast run-sudoku -- 9x9 MRV fuzz 5
# Or (after build)
./zig-out/bin/sudoku-backend 9x9 MRV fuzz 5From here on out i will just refer to the CLI as
sudoku-backendremember to use the correct path to the binary ( including -- if using zig build).
Keeps generating good random puzzles (up to 4 billion) and solves them.
sudoku-backend 9x9 MRV gen_100k_bench How long it takes to generate 100k good random puzzles.
See all available commands by running:
sudoku-backend