搜索资源列表
Searching
- 整理了各种查找算法:多种数据结构的顺序查找;对分查找;关键字查找-Organize a variety of search algorithms: a variety of data structures in order to find of sub-search keywords to find more
hash
- 已知某哈希表的装载因子小于1,哈希函数 H(key)为关键字(标识符)的第一个字母在字母表中 的序号,处理冲突的方法为线性探测开放定址法。 试编写一个按第一个字母的顺序输出哈希表中所有 关键字的算法。-Known load factor of a hash table is less than 1, the hash function H (key) for the keywords (identifiers) of the first letter of the alphabe
testbtree
- 将树型显示在屏幕上。全部关键字插入完毕时显示树型,之后每完成一次插入或删除操作后也显示当前的树型。-The tree is displayed on the screen. All keyword insertion is complete display tree, also displays the current tree after each time you insert or delete operation.
Internal-comparison-algorithm
- 系统用srand()函数产生一个以当前时间开始的随机种子。其产生的种子用选择排序、冒泡排序、快速排序将顺序表中的数字排好,设置变量记录每种排序关键字的移动次数和关键字的比较次数。选择排序:利用L.length-1个循环,将随机种子按从小到大的顺序排好。-System with srand () function generates a random seed to start the current time. Which produces seeds with selection sort,
顺序查找代码
- 顺序查找适合于存储结构为顺序存储或链接存储的线性表。 基本思想:顺序查找也称为线形查找,属于无序查找算法。从数据结构线形表的一端开始,顺序扫描,依次将扫描到的结点关键字与给定值k相比较,若相等则表示查找成功;若扫描结束仍没有找到关键字等于k的结点,表示查找失败。
