Since this data structure is supported by several LinkedList , for which the initial capacity constructor parameter does not matter.
HashMap is supported by an array (contiguous memory space), for which it makes sense to set the initial capacity, because overflowing the initial size of this table causes HashMap to redistribute the new table with the increased size, which is very expensive.