Re:How many ways are there to sort GUIDs?
by cyphar on Tuesday April 30, 2019 @12:05AM
(#19785084)
Binary search is a cheap way of getting an O(log n) .contains() without the additional logic of proper AVL/RedBlack trees (or hashmaps). If you need to check whether an element is a member of a set many times, the once-off O(n log n) setup cost is no worse than any other trees (it is worse than hashmaps but those have other downsides).
[ Parent
| on HN ]
There are no comments on this comment yet.