Implement a hash table with put/get
Company: Paradromics
Role: Software Engineer
Category: Coding & Algorithms
Difficulty: medium
Interview Round: Technical Screen
Overview: This question evaluates implementation and design skills for hash-based data structures, testing competency in data structures, hashing, collision handling, and achieving expected O(1) put/get performance in the Coding & Algorithms domain.
Constraints
- Inputs are Python literals matching the function signature.
- Return a deterministic exact-match value.
Examples
Input: (2, [["put","a",1],["put","b",2],["get","a"],["get","c"]])
Expected Output: [1, None]
Explanation: Put and get values with missing returning None.
Input: (1, [["put","a",1],["put","b",2],["get","a"],["get","b"],["put","a",3],["get","a"]])
Expected Output: [1, 2, 3]
Explanation: A single bucket forces collision handling and update.
Hints
- Use a list for each bucket.
- Scan a bucket to update or find a key.