First implementation, recursion, binary search