binary search and variants