-
Description:
对整型有序关键码序列进行折半查找,待排序序列以数组存储。如果找到待查记录,返回找到的位置下标,并删除该关键码记录;如果没找到待查记...
Description:
对整型有序关键码序列进行折半查找,待排序序列以数组存储。如果找到待查记录,返回找到的位置下标,并删除该关键码记录;如果没找到待查记录,返回0,并将待查记录插入到适当位置,即该查找属于动态查找。输出查找过程中每一轮的low,mid,high 值,以及与给定值相比较的关键码值,并输出最后找到的位置,及变化后的数组。
注意:该数组为整型,数组中关键码存储位置为r[1]~r[n],r[0]留作它用,且关键码个数大于4.
Input Format:
第一行输入数组中记录个数n
第二行输入n个有序的整型关键码,以空格隔开
接下来输入三个待查关键码,每个关键码占一行
Output format:
对于每个关键码,分别输出:
找到给定值之前的每一轮的low,mid,high及相比较的待查找序列中的关键码,以空格隔开
接下来一行输出查找到的位置
接下来一行输出变化后的待查找序列
-Description:
The key codes for integers ordered sequence of binary search until the sorting sequence to an array of storage. If you find a complete set of records, returns to find the location of the next standard, and delete the key code is recorded if not find a complete set of records, returns 0, and a complete set of records inserted into the appropriate location, that is, the search was part of search. Find out the process for each one of the low, mid, high value, as well as compared to the value given the key code value and output of the last to find the locat
- 2023-05-15 19:40:03下载
- 积分:1
-
Serial Port Reader
这是用delphi7.0开发的串口阅读器
- 2023-02-13 07:50:04下载
- 积分:1
-
CRC 算法的实现,在通讯使用它可提高通讯的可靠性.
CRC 算法的实现,在通讯使用它可提高通讯的可靠性.-CRC algorithm implementation, the communication can use it to improve communications reliability.
- 2022-09-17 11:10:03下载
- 积分:1
-
软件下载管理程序
软件下载管理程序-downloading software management procedures
- 2022-12-29 03:05:04下载
- 积分:1
-
在Windows Mobile手机操作系统下,实现串口通信功能。
在Windows Mobile手机操作系统下,实现串口通信功能。-In Windows Mobile phone operating system, realize the serial communication function.
- 2023-03-26 23:05:03下载
- 积分:1
-
做成只有打开文件,回放,快进,快退的界面的YUVTORGB的运行程序
做成只有打开文件,回放,快进,快退的界面的YUVTORGB的运行程序-caused only open the file, playback, fast forward, fast interface with its operational procedures YUVTORGB
- 2022-08-22 12:52:58下载
- 积分:1
-
GDI+阴影与光辉效果,转自CODEPROJECT。NET
GDI+阴影与光辉效果,转自CODEPROJECT。NET-GDI+ Shadow and brilliant effect, carried CODEPROJECT. NET
- 2022-02-02 04:05:15下载
- 积分:1
-
travle
深度优先遍历和广深优先遍历的实现及实现源代码-travle
- 2022-03-17 17:29:03下载
- 积分:1
-
获取心率的测试代码
通过定时器中断和外部中断获取心率的次数,使用的是飞思卡尔的低功耗芯片MKL25平台。这个只是测试代码,提供一个测试方式。
- 2022-08-11 10:51:33下载
- 积分:1
-
使用VC6.0开发的钩子程序,它不仅能偷窥各种桌面程序的密码框,还能窥到IE页面中的密码框。...
使用VC6.0开发的钩子程序,它不仅能偷窥各种桌面程序的密码框,还能窥到IE页面中的密码框。-HOOK program developed in VC6.0,it can spy many kinds of password.
- 2023-04-14 02:15:03下载
- 积分:1