关于二分查找法的优化

二分查找法中的 mid =  low + (high - low) / 2; 考虑对 1/2进行改进,改成 mid = low + (key - a[low]) / (a[high] - a[low])  * (high - low)
相关文章
相关标签/搜索