8 Queens Problem using Backtracking

You are given an 8x8 chessboard, find a way to place 8 queens such that no queen can attack any other queen on the chessboard. A queen can only be attacked if it lies on the same row, or same column, or the same diagonal of any other queen. Print all the possible configurations.


This is a companion discussion topic for the original entry at http://iq.opengenus.org/8-queens-problem-backtracking/