n-queens Classic N-Queens problem in Java The java program takes the n x n board size as input (just n), and outputs the first solution it finds for n queens on an n x n board.