• recategorized by
538 views
1 1 vote

In the $n$-queens completion problem, the input is an $n \times n$ chess board with queens on some squares, and the goal is to determine if there is a way to place more queens so that the total number of queens is $n$ and no two queens attack each other (two queens are said to attack each other if they are on the same row, or they are on the same column, or they are on the same diagonal).

Consider the following statements:

  1. The $n$-queens completion problem is decidable.
  2. The $n$-queens completion problem is decidable in time $O\left(n^{n^{n}}\right)$.
  3. The problem of "checking whether a given program solves the $n$-queens completion problem" is decidable.
  4. The problem of "checking whether a given program solves the $n$-queens completion problem in time $O\left(n^{n^{n}}\right)$ " is decidable.
  5. The problem of "checking whether a given program solves the $n$-queens completion problem" is decidable in time $O\left(n^{n^{n}}\right)$.

Which of the above is true?

  1. Only $\text{(i) and (ii)}$.
  2. Only $\text{(i) and (iii)}$.
  3. Only $\text{(i), (ii) and (iv)}$.
  4. Only $\text{(iii),(iv) and (v)}$.
  5. Only $\text{(i), (iii) and (iv)}$.

     

1 Answer

0 0 votes
n-queens problem is solvable in $\mathcal{O}(N!)$

1 & 2.  $\mathcal{O}(N!) < \mathcal{O}(N^N) < \mathcal{O}(N^{N^N})$
3 & 5. It is basically halting problem which is undecidable.
4. Since there is a finite upper bound for computation, it is decidable
Answer:
Position:
Show:

Related questions

0 0 votes
1 1 answer
605
605 views
admin asked Jan 13, 2024
605 views
For two languages $\text{A, B}$ over the alphabet $\Sigma$, let the perfect shuffle of $\text{A}$ and $\text{B}$ be the language\begin{Bmatrix}w=a_1 b_1 a_2 b_2 \cdots a_...
0 0 votes
1 1 answer
531
531 views
admin asked Jan 12, 2024
531 views
A subset $\text{S}$ of the rational numbers is said to be "nice" if for every infinite sequence of $x_1, x_2, \ldots$ of elements from $\text{S}$, there is always two ind...
0 0 votes
1 1 answer
588
588 views
admin asked Jan 12, 2024
588 views
There is a $100 \mathrm{~cm}$ long ruler that has 11 ants on positions $0 \mathrm{~cm}, 10 \mathrm{~cm}, 20 \mathrm{~cm}, 30 \mathrm{~cm}$, ..., $100 \mathrm{~cm}$. The a...
0 0 votes
0 0 answers
513
513 views
admin asked Jan 13, 2024
513 views
The four nucleotides in $\text{DNA}$ are called $\text{A, C, G}$, and $\text{T}$. Consider the following languages over the alphabet $\{\mathrm{A}, \mathrm{C}, \mathrm{G}...