Content deleted Content added
No edit summary |
fix broken link |
||
Line 3:
A single "problem" is an entire set of related questions, where each question is a finite-length [[string]]. For example, the problem [[Integer factorization|''FACTORIZE'']] is: given an integer written in binary, return all of the [[prime number|prime]] factors of that number. A particular question is called an ''instance''. For example, "give the factors of the number 15" is one instance of the ''FACTORIZE'' problem.
The time complexity of a problem is the number of steps that it takes to solve an instance, as a function of the size of the instance. If an instance that is ''n'' bits long can be solved in ''n''<sup>2</sup> steps, then we say it has a time complexity of ''n''<sup>2</sup>. Of course, the exact number of steps will depend on exactly what machine or language is being used. To avoid that problem, we generally use [[Big
<h2>Decision Problems</h2>
|