HashSet uses linked lists to handle hash collisions.
When two objects produce the same hash code, HashSet stores them in a linked list within the same bucket. This ensures that all elements can be accessed through traversal, though performance can degrade if many collisions occur.