摘要: 源程序: // 32 66 90//15,32,9,22,18 43,66,49,35,53 90,78,71,86 //分析:分块查找由索引查找和子表查找两步完成。设n个数据元素的查找表分为m个子表,且每个子表//均为t个元素,则t=n/m 。这样,分块查找的平均查找长度为:// ASL=ASL索 阅读全文
posted @ 2019-11-21 11:04 bobo哥 阅读(411) 评论(0) 推荐(0)
摘要: 源程序: //二分查找法#include <stdio.h>#define MaxSize 8typedef struct{ int stuno; char stuname[20];}TableElem; TableElem stu[]={{1001,"zhang"},{1009,"wang"},{ 阅读全文
posted @ 2019-11-21 10:31 bobo哥 阅读(299) 评论(0) 推荐(0)
摘要: 源程序: #include <stdio.h>#define MaxSize 8typedef struct{ int stuno; char stuname[20];}TableElem; TableElem stu[]={{1001,"zhang"},{1009,"wang"},{2005,"s 阅读全文
posted @ 2019-11-21 09:15 bobo哥 阅读(790) 评论(0) 推荐(0)