What is insertion order in Java?

What is insertion order in Java?
Answer
Insertion order refers to the order in which you are adding elements to the data structure (i.e., a collection like List , Set , Map , etc..). For example, a List object maintains the order in which you are adding elements, whereas a Set object doesn’t maintain the order of the elements in which they are inserted.
 

Tìm kiếm

Back
Top