This way, when we need to find an element, we quickly calculate from it the cell number in the array. Accessing an array cell by its number is also a very fast operation. And within the cell, we take the element's address and quickly retrieve it from memory. The complexity is O(1). However, all efficiency depends on the hash function, which should evenly distribute the elements throughout the array. The books explain how to create such hash functions.
Furthermore, a hash function can return the same hash for different elements - "Collision" occurs. In this case, the element that first occupies the array cell stores a pointer to the next element with the same hash. This results in a chain of elements with the same hash, called a Bucket. During a search, if we calculate the hash but find the wrong element in the cell, we take the pointer to the next element in the bucket and follow the chain until we find our element.
A limitation of hash search is that all elements in the list must be unique, so it is typically used for lists with key-value elements.
Here are some PDF books on Hash Table Search:
Handbook of Data Structures and Applications
2004 by Dinesh P. Mehta, Sartaj Sahni

Download PDF
C++: object-oriented data structures
1994 by Saumyendra Sengupta, Carl P. Korobkin

Download PDF
Algorithms and Complexity, Volume 1
1990 by Jan Leeuwen

Download PDF
See also: Top 10 eBook Organizers
How to download PDF:
1. Install Gooreader
2. Enter Book ID to the search box and press Enter
3. Click "Download Book" icon and select PDF*
* - note that for yellow books only preview pages are downloaded


