hash查找与二分查找
摘要:
今晚心血来潮,实现了下hash查找,查找时间很快.当然hash查找到底有多快,也用了二分查找做比较.代码如下所示: 1 #include <stdio.h> 2 #include <stdlib.h> 3 #include <sys/time.h> 4 5 #define TABLE_SIZE 100 6 typedef int elemtype; 7 #define ELEM_COUNT 3000000 8 9 typedef struct st_node 10 { 11 elemtype data; 12 struct st_node *next; 1. 阅读全文
posted @ 2013-03-09 18:38 灭人沉醉 阅读(2210) 评论(2) 推荐(1)
浙公网安备 33010602011771号