From af4499ecbd45309ef14ed041c0e9b1521b03143b Mon Sep 17 00:00:00 2001 From: Antti H S Laaksonen Date: Sat, 25 Feb 2017 12:39:37 +0200 Subject: [PATCH] Fix time complexity table [closes #9] --- chapter02.tex | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/chapter02.tex b/chapter02.tex index b686b13..b2212ac 100644 --- a/chapter02.tex +++ b/chapter02.tex @@ -309,14 +309,13 @@ assuming that the time limit is one second. \begin{center} \begin{tabular}{ll} -input size & required time complexity \\ +typical input size & required time complexity \\ \hline -$n \approx 10$ & $O(n!)$ \\ -$n \approx 20$ & $O(2^n)$ \\ -$n \approx 100$ & $O(n^3)$ \\ -$n \approx 1000$ & $O(n^2)$ \\ -$n \approx 10^5$ & $O(n \log n)$ \\ -$n \approx 10^6$ & $O(n)$ \\ +$n \le 10$ & $O(n!)$ \\ +$n \le 20$ & $O(2^n)$ \\ +$n \le 500$ & $O(n^3)$ \\ +$n \le 5000$ & $O(n^2)$ \\ +$n \le 10^6$ & $O(n \log n)$ or $O(n)$ \\ $n$ is large & $O(1)$ or $O(\log n)$ \\ \end{tabular} \end{center}