Monday, 25 April 2016

What goes wrong if the HashMap key has same hashcode value ?


Hashcode Collision

If the multiple keys in HashMap has same hashcode value , it leads to ‘Hashcode Collision’ where all the values are stored in same bucket.

Hence, the searching time increases quadradically.

No comments:

Post a Comment

Note: only a member of this blog may post a comment.