4 ms·
If they're not unique, it will have to linearly search through items with duplicate keys. This situation will begin to approach O(n) time, which isn't good.
by rand_r 10y ago
If they're not unique, it will have to linearly search through items with duplicate keys. This situation will begin to approach O(n) time, which isn't good.
- krona 10y agoUnless you're using an Open addressing scheme like cookoo which ensures constant lookup time in the worst case