hashmap - Calculating a hash function -
there standard hash function take mod key in order define address. is, h(k) = k(mod) p (where p prime number).this called division method. have seen variation of "division method" first multiply key prime , take mod. example: h(k) = (k*17) mod 11. purpose multiply key prime (17,37...) before calculating mod?? improve distribution of keys?
Comments
Post a Comment