-Hashin is a technique used for storing and retrieving information as quickly as possible. -The worst-case complexity of hashing is still O(n), but it gives O(1) on the average.
• CreatHashTable: Creates a new hash table • HashSearch: Searches the key in the hash table • Hashlnsert: Inserts a new key into the hash table • HashDelete: Deletes a key from a hash table • DeleteHashTable: Deletes the hash table
Hashing has four key components:
- Hash Table
- Hash Functions
- Collisions
- Collision Resolution Techniques
• Minimize collision • Be easy and quick to compute • Distribute key values evenly in the hash table • Use all the information provided in the key • Have a high load factor for a given set of keys
- Nth Fibonacci Number
- Non-Repeating Element
- First Repeating Element
- Intersection of two arrays
- Key PairSubarray with 0 sum
- Winner of an election
- Pairs with Positive and Negative values
- Prime Number
- Non Repeating Numbers