写一个函数,用二分法在已按从小到大排序的整型数组 pst (数组包含len 个元素) 中查找一个整数 n,若 n 在数组中,函数返回数 n 在数组中的下标;否则返回 -1。所谓二分法查找是初始查找区间的下界为 0,上界为 len - 1,查找区间的中间元素下标为 k = (下界 + 上界) / 2 ;若 pst 等于 n ,查找成功;若...
Latest commit Cannot retrieve latest commit at this time. History History