Qm

Four queens on a four-by-four board

A queen attacks along her row, her column and both diagonals.

  1. In how many ways can four queens be placed on a 4 by 4 board so that no two attack each other? Find them by hand.
  2. Why can no queen be in a corner? How many solutions does the 8 by 8 board have?
Show a hint

Each row must hold exactly one queen. Try the queen in row 1 in each column in turn and see what the other rows are forced to do.

Your answer

Solving needs a free account

Answers, streaks and solutions unlock when you are signed in. Reading the question and the hint stays free.

Discussion

Sign in to join the discussion · reading is open to everyone

💡 Discussion rules

  1. No full solutions here. Hints and approaches only.
  2. Complexity, edge cases and intuition are the point.
  3. Interview experiences are welcome. Respect your NDAs.

Loading discussion…

Learn the concepts

The theory behind this question.

Related questions

How many squares does a queen attack?The fewest queens that guard the whole boardHow many rectangles are on a chessboard?Two rooks that do not attack each other100 prisoners and the light bulb
All questions →