文件名称:half
介绍说明--下载内容均来自于网络,请自行研究使用
折半查找的算法思想是将数列按有序化(递增或递减)排列,查找过程中采用跳跃式方式查找,即先以有序数列的中点位置为比较对象,如果要找的元素值小于该中点元素,则将待查序列缩小为左半部分,否则为右半部分。通过一次比较,将查找区间缩小一半。 折半查找是一种高效的查找方法。它可以明显减少比较次数,提高查找效率。但是,折半查找的先决条件是查找表中的数据元素必须有序-Binary search algorithm idea is to sequence by ordering (ascending or descending) order, find the process using jump way to find that the first series to the middle point of order to compare objects to find the element value is less than if The midpoint of the element of unknown origin will be reduced for the left part of the sequence, otherwise the right half. Through a comparison, will look for half the interval narrowing. Binary search is an efficient search method. It can significantly reduce the number of comparisons to improve search efficiency. However, a prerequisite for binary search to find data in the table element must be ordered
(系统自动生成,下载前可以参看下载内容)
下载文件列表
折半查找.cpp