The really, really true answer is that I didn't know it existed. However, if it is a general function then it contains overhead to handle general cases. The overhead issues should be addressed before use (unless convenience overcomes speed in this application).
art -------------- Original message ---------------------- From: Glenn Linderman <[EMAIL PROTECTED]> > On approximately 10/13/2005 6:12 PM, came the following characters from > the keyboard of Glenn Linderman: > > > On approximately 10/13/2005 1:18 PM, came the following characters from > > the keyboard of [EMAIL PROTECTED]: > > >> Two side notes: > >> 1. My initial search algorithm was (seriously) flawed. I > >> code in Ada at work and there was some dialectic confusion when > >> I translated the code to 'C'. Sigh. > > > > Ah. So my comment was beneficial in causing you to find a bug. Good. > > And it must have manifested itself in terms of performance, since > > performance testing found it! So I guess I don't have to apologize too > > much for making you do extra work. > > Oh, and I should have also asked why you didn't use the ANSI C function > bsearch to help in your searching. > > -- > Glenn -- http://nevcal.com/ > =========================== > Having identified a vast realm of ignorance, Wolfram is saying that much > of this realm lies forever outside the light cone of human knowledge. > -- Michael Swaine, Dr Dobbs Journal, Sept 2002