The P versus NP problem, often shortened to P versus NP, is the determination of whether all NP-problems are actually P-problems.
If , then some NP-problems
cannot be solved in polynomial time. This does
not imply that every NP-problem requires an exhaustive
search. If
, then every NP-problem
has a polynomial time algorithm
(Cook).
The problem is one of the Millennium Prize Problems and remains unsolved. Determination of the status of this question would have dramatic consequences for the potential speed with which many difficult and important problems could be solved.
Naik and Selman's hypothesis B states that every total function on binary strings computable in polynomial time with one nonadaptive
batch of queries to an NP-problem is computable in
polynomial time with
adaptive queries to an NP-problem, where
is the input length. Nonadaptive queries are fixed before
any answers arrive, while adaptive queries can depend on previous answers. Leitmeir
(2026) reports a Lean proof that this inclusion holds if and only if
.
In the Season 1 episode "Uncertainty Principle" (2005) of the television crime drama NUMB3RS, math genius Charlie Eppes uses the game minesweeper as an analogy for the P vs. NP problem.