You may be getting "best case" and "worst case" mixed up. Clever short-circuits in implementations of algorithms often increase the best case, but only if the data behaves certain ways. There are usually mixes of data that defeat the short-cuts. O() is about worst-case behavior.
In reply to Re: Re: An informal introduction to O(N) notation
by dws
in thread An informal introduction to O(N) notation
by dws
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |