Comparing Hash Table Implementations

Possible Duplicate:
Related Hash Tables and Open Address Hash Tables

In general, I saw two hash table implementations. The first is implemented as two arrays, one of which contains keys, and the other - values. The second has a single array, and then a linked list containing objects with a key.

What are the advantages and disadvantages of one implementation over another? Both look equally good to me in terms of collision handling and input / receive.

+3
source share
2 answers

As Johna says, we call the first example open addressing, and the last - chain.

, , - , , , . , .

, . ; , .

+2

Wikipedia. , , - ( ) ( ).

+3

All Articles