Welcome to the Sudoku Solver project! This repository contains two implementations of a Sudoku solver, each utilizing different methods for input.
- User Input: Solve Sudoku puzzles by entering them directly through the console.
- File Input: Solve Sudoku puzzles by reading them from an external file.
This implementation allows users to input the Sudoku puzzle directly via the console. The program will then solve the puzzle and display the solution.
This implementation reads the Sudoku puzzle from an external file. The file should be formatted such that the puzzle can be easily parsed by the program. The program will solve the puzzle and display the solution.
- C++ compiler
- Basic knowledge of C++ programming
- Clone the repository:
git clone https://github.com/whdhdyt21/Sudoku.git
- Navigate to the project directory:
cd Sudoku
- Compile the program:
g++ sc_Sudoku.cpp -o sc_sudoku
- Run the compiled program:
./sc_sudoku
- Follow the on-screen instructions to input the Sudoku puzzle.
- Ensure your input file is formatted correctly.
- Compile the program:
g++ Sudoku2.cpp -o sudoku2
- Run the compiled program with the input file as an argument:
./sudoku2 input.txt
Run the program and input the Sudoku puzzle as prompted. The program will display the solution after processing the input.
Prepare a text file (input.txt
) with the Sudoku puzzle formatted correctly. Run the program with the file as an argument to see the solution.
Contributions are welcome! Please follow these steps to contribute:
- Fork the repository.
- Create a new branch (
git checkout -b feature-branch
). - Make your changes and commit them (
git commit -m 'Add new feature'
). - Push to the branch (
git push origin feature-branch
). - Create a new Pull Request.
This project is licensed under the MIT License. See the LICENSE
file for more details.
For any questions or feedback, please open an issue or contact the project maintainer at wahidh776@gmail.com.
Thank you for exploring the Sudoku Solver project! We hope these implementations help you solve Sudoku puzzles more efficiently.