Problem 2: 4-Queen Problem [30 Points]
The 4-Queen Problem consists in placing four queens on a \( 4 \times 4 \) chessboard so that no two queens can capture each other. That is, no two queens are allowed to be placed on the same row, the same column or the same diagonal.
The following figure illustrates a goal state to the 4-Queens Problem: none of the 4 queens can capture each other.
\begin{tabular}{|l|l|l|l|}
\hline & & Wii & \\
\hline Wii & & & \\
\hline & & & \\
\hline & & & \\
\hline
\end{tabular}
Initial State
Goal State