On Friday 18 May 2001 06:16, MaD dUCK wrote:
> also sprach Zak Greant (on Thu, 17 May 2001 09:35:18PM -0600):
> > Or just use a simple chain of if statements :)
>
> yeah, but that's so O(n) !
> i can do in O(lg n)
> or, given n CREW processors, in O(1) time!
>
> yes, i have just finished my computational theory and computer
> algorithms honors exam.
Well, then you *do* know that O(log n) can be slower than O(n), right? :)
For a small number of ranges the chained ifs are most likely faster...
--
Christian Reiniger
LGDC Webmaster (http://sunsite.dk/lgdc/)
(A)bort (R)etry (P)retend this never happened ...
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]