Counting Solutions

How many ways can one put nn queens on an n×nn \times n chessboard so that no two queens attack each other In other words, how many points can be placed on an n×nn \times n grid so that no two are on the same row, column, or diagonal

Parameters

  • nn: number of queens, size of chessboard

Filters

Computational Model

Randomization

Approximation

Algorithms Table

Displaying 6 of 6 algorithms

See more
Rivin, Zabih1992O(8npoly(n))O(8^n \text{poly}(n))O(8nn2)O(8^n n^2)
Dijkstra1972O(n!)O(n!)O(n)O(n)
Method of determinants1874O(n!)O(n!)
Gunther Determinants solution1874O(n!)O(n!)O(n!)O(n!)
Naive + 1 queen per row restriction1850O(n!)O(n!)O(n)O(n)
Naive Algorithm1848O(nn)O(n^n)O(n)O(n)

Reductions Table

Insuffient Data to display table

Other relevant algorithms

Insuffient Data to display table