For N=1000, 2^n ~~ 1e301, while n^2/2 ~~ 1e5. The first will never finish in the lifetime of the universe, the second in a blink of an eye.
-QM
--
Quantum Mechanics: The dreams stuff is made of
In reply to Re^3: Puzzle: Given an array of integers, find the best sequence of pop / shift...
by QM
in thread Puzzle: Given an array of integers, find the best sequence of pop / shift...
by TedPride
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |