Jon Zeppieri wrote:


> The Bucket class really provides a simple, small linked list
> implementation.  Hashtable and HashMap both use the strategy known as
> "external chaining" to resolve collisions.
> 
> Open addressing (linear or quadratic probing, or double hashing), I
> admit, is generally faster for put() and get() operations.  But it
> seriously complicates the data structure in the presence of a remove()
> operation.


Yes, I know and I'm not advocating using linear probing, just reducing
one extra object for external chaining - Bucket instance. Instead of
going through

Bucket[] -> Bucket -> Node1 -> Node2 -> ...

I propose using

Node[] -> Node1 -> Node2 -> ...

Artur

Reply via email to