binary search for char and string data type