This question evaluates understanding of hash tables and low-level data-structure implementation, including hashing, collision resolution, resizing/rehashing, and performance guarantees for put/get/remove operations.
Implement a key-value map type (a “dictionary” / hash map) from scratch, without using the language’s built-in dictionary/map as the underlying storage.
put(key, value)
get(key) -> value | null
remove(key)
O(1)
average time per operation.
Key: Hashable
)?