complexity theory - Example of a factorial time algorithm O( n! ) -


i'm studying time complexity in school , our main focus seems on polynomial time <code>o(n^c)</code> algorithms , quasi-linear time <code>o(nlog(n))</code> algorithms occasional exponential time <code>o(c^n)</code> algorithm example of run-time perspective. however, dealing larger time complexities never covered.

i see example problem algorithmic solution runs in factorial time <code>o(n!)</code>. algorithm may naive approach solve problem cannot artificially bloated run in factorial time.

extra street-cred if factorial time algorithm best known algorithm solve problem.

generate permutations of list

you have n! lists, cannot achieve better efficiency o(n!).


Comments

Popular posts from this blog

How can I fetch data from a web server in an android application? -

android - java.net.UnknownHostException(Unable to resolve host “URL”: No address associated with hostname) -

jquery - How can I dynamically add a browser tab? -