set is an Associative container which contains a sorted set of unique objects of type Key. Each element may occur only once, so duplicates are not allowed.
There are four kind of Associative containers:
The value of the elements in a set cannot be modified once in the container, i.e., the elements are always constant. But they can be inserted or removed from the container.
set containers are generally slower than
unordered_set containers in accessing individual elements by their key, but they allow the direct iteration on subsets based on their order.
This is a companion discussion topic for the original entry at http://iq.opengenus.org/set-cpp-stl/