Hash Table

1/0
1.0x

Hash Table

O(1)Space: O(n)

Pseudocode

1procedure insert(key)
2 index ← hash(key) mod size
3 append key to bucket[index]
4procedure search(key)
5 index ← hash(key) mod size
6 for each item in bucket[index]
7 if item = key then return true
8 return false
9procedure delete(key)
10 index ← hash(key) mod size
11 remove key from bucket[index]