1
21kviews
Write an algorithm to solve the N-Queens problem. Show working for N=4.
1 Answer
written 3.0 years ago by | • modified 3.0 years ago |
The N - Queens problem is to place N - queens in such a manner on an N x N chessboard that no queens attack each other by being in the same row, column, or diagonal.
Here, we solve the problem for N = 4 Queens.
Before solving …