On 5/13/12 4:13 AM, Andrei Alexandrescu wrote:
On 5/11/12 10:38 PM, Ary Manzana wrote:Add a binarySearch(range, object) method that does all of that?I mean, I don't want to write more than a single line of code to do a binarySearch...assumeSorted(range).contains(object) is still one line, safer, and IMHO more self-explanatory. Andrei
Ok. When more people start saying that they can't find a binarySearch method... will you change your mind? :-)
(but let's first wait until that moment comes)