A set
is an associative container while a list
is a sequential container. Elements in list
can be sorted by user while elements in set
is sorted automatically (except unordered version). A list
can be ordered while a set
is un-ordered. We can't enforce an arbitrary order by placing an arbitrary element in an arbitrary position in a set
.