Hash function
The basic idea in hashing is the transformation of a key into the corresponding location in the hash table. This is done by a hash function. A hash function can be defined as a function that takes key as input and transforms it into a hash index. It is usually denoted by H
H: K -àM
Where H is a Hash function
K is a set key
M is a set of memory addresses.
Sometimes such a function H may not yield distinct values it is possible that two different keys k1 and k2 will yield the same hash address. This situation is called Hash collision.
There are different types of Hash functions are available. To chose the hash function H : K M there are two things to consider. Firstly the function H should be very easy and quick to compute. Secondly the function H should distribute the keys to the number of locations of hash table with less no of collisions. Different hash functions are
1. Division reminder method
2. Mid square method
3. Folding method.
Data Structure & Algorithms Assignment Help, Live Experts
Struggling with data structure problems? Data structure subject is quite tough to learn? Need quick assistance in data structure questions? ExpertsMind.com is right place for you where your search ends, We at ExpertsMind offer online data structure assignment help, data structure homework help and data structure and algorithms question’s answers by best online support by qualified tutors.
ExpertsMind.com - Hash Function Assignment Help, Hash Function Homework Help, Hash Function Assignment Tutors, Hash Function Solutions, Hash Function Answers, Define Hashing Assignment Tutors