> In the set, which element is picked from the sets? Okay, the specification does not say whether set operations are stable. Neither does not specify sorting algorithm stability. However, there is a separate std::stable_sort() that guarantees stability Thanks, -- Mikhail