How HashTable and HashMap key-value are stored in the memory?

后端 未结 4 1576
谎友^
谎友^ 2020-12-04 22:46

I understand there is a hashing technique is applied to a key to store its value in the memory address.

But I don\'t understand how the collision is happeni

4条回答
  •  盖世英雄少女心
    2020-12-04 23:08

    As default implementation hashCode() function in Object class return the memory address as the hash which is used as key in HashTable & HashMap.

提交回复
热议问题