What exactly is bucket in hashmap?
No, a bucket is each element in the array you are referring to. In earlier Java versions, each bucket contained a linked list of Map entries. In new Java versions, each bucket contains either a tree structure of entries or a linked list of entries. From the implementation notes in Java 8: /* * Implementation … Read more