This project implements a recursive backtracking solution to the classic N-Queens problem. It finds valid configurations where N queens can be placed on an NΓN chessboard such that none attack each other.
- Solves the N-Queens puzzle using recursion and backtracking.
- Prints the board with queen positions.
- Written in C for educational purposes.
- Clone the repository:
git clone https://github.com/Asaf-Alber/Queen-Puzzle.git
cd Queen-Puzzle
- Compile the code:
gcc queens.c -o queens
- Run the program:
./queens
Q . . . . . . .
. . . . Q . . .
. . . . . . Q .
. . . Q . . . .
. . . . . Q . .
. Q . . . . . .
. . . . . . . Q
. . Q . . . . .
Created by Asaf Alber
This project is licensed under the MIT License.