Features of HashMap
Hashmap internals
10 most common coding questions
Limitations of hashmap
Concurrent HashMap vs [Link]()
ConcurrentHashMap internals
Linked HashMap internals
Interview Questions on ConcurrentHashMap
Interview Questions on LinkedHashMap
Interview Questions on Hashmap
What are HashMaps?
HashMap provides the basic implementation of Map interface in Java. It is a
data structure which stores the data in key-value pairs, where every key is
mapped to a value.
You can think of it as a dictionary where you can look up a word (key) and find
its corresponding definition (value). Now, you might be wondering, where does
hashing come into use?
Behind the scenes, HashMaps use hashing to quickly locate the value
associated with a given key. This gives it the power of O(1) time complexity.
Here are some important features of hashmap that you must know:-
1. Data is stored in key-value pairs.
2. Uses hashing to store and retrieve data.
3. Each key must be unique.
4. It can dynamically resize itself as required to accommodate more key-value
pairs.
5. Allows null values and only one null key.