ash[k]==key){printf("hash[%d]=%d,,,k,key);flag=l;}else{kl=k+l;while(kl<MAX&&hash[kl]!=key)kl++;if(kl<MAX)printf(,,hash[%d]=%d"/kl/key);flag=l;k2=0;if(!flag){while(k2<k&&hash[k2]!=key)k2++;if(k2<k){printf("hash[%d]=%d"/k2,key);flag=l;}}if(flag){printf(喳找成功!\n”);return;}else{printff喳找失败!\n”);return;}}}voidmain(){inti,key,k,sum=O;inthash[MAX];for(i=0;i<MAX;i++)hash[i]=O;printf(“请输入数据,以0结束:\n“);scanf("%d",&key);sum++;while(key&&sum<MAX){ins_hash(hash,key);scanf("%dH,&key);sum++;}printfCXn");out_hash(hash);printfCXn");printff'请输入查找的值门;scanf(”%cT:&k);hash_search(hash,k);printf(W);C:XDocuaentsandSettings\K\桌面\Debug\哈希表查找・exe犢输入数据,如结束:2653716111591548190liash[0]=llJ)ash[l]=l卜ash[23=19卜ash【4X26卜ash[5"5Slash[6]=37hash[?]=61卜ash【8]=59Slash[9]=15hashtl0]=48b输入查找的t:3?卜ash【6X3?查找成功?Pressanykeytocontinue