Binary search and comparable mergesort