I was going through Rehashing process in hashmap or hashtable which explains the beautiful concept of HashMap rehashing. I have a question about it.
Consider a case where initial capacity of HashMap is 16 and load factor is 0.75. Now, 12 elements are added to the HashMap, but they all end up in the same bucket due to a poor hashCode
implementation. The other 15 buckets do not contain any elements. Will the HashMap rehash?