https://github.com/akzare/Algorithms/blob/master/src/main/python/algorithms/search/BinarySearch.py#L39 has a typo, should be if (hi - lo) <= self.EPS: break