3 ms·
Tim Bray wrote a post, "On the Goodness of Binary Search," in which he stated, "Simplicity is good, and binary search, coded properly, (see below) is awfully da
by SloopJon 5y ago
Tim Bray wrote a post, "On the Goodness of Binary Search," in which he stated, "Simplicity is good, and binary search, coded properly, (see below) is awfully damn simple" (emphasis in original):
https://www.tbray.org/ongoing/When/200x/2003/03/22/Binary https://www.tbray.org/ongoing/When/200x/2003/03/22/Binary
In an update to his post, Tim linked to Joshua Bloch's "Extra, Extra - Read All About It: Nearly All Binary Searches and Mergesorts are Broken" post about the problems you describe:
https://ai.googleblog.com/2006/06/extra-extra-read-all-about-it-nearly.html https://ai.googleblog.com/2006/06/extra-extra-read-all-about...