Standard C++ Library Class Reference
Deletes the elements in the range (first, last). Returns an iterator pointing to the element
following the last deleted element, or end() if there were no elements after the deleted range.
iterator
find (const key_value& x) const;
Returns an iterator that points to the element equal to x. If there is no such element, the iterator
points to the past-the-end value.
pair<iterator, bool>
insert (const value_type& x);
Inserts x into self according to the comparison function object. The template's default
comparison function object is less (<). If the insertion succeeds, it returns a pair composed of the
iterator position where the insertion took place, and true. Otherwise, the pair contains the end
value, and false.
iterator
insert (iterator position, const value_type& x);
x is inserted into the set. A position may be supplied as a hint regarding where to do the
insertion. If the insertion may be done right after position then it takes amortized constant time.
Otherwise it will take 0 (log N) time. The return value points to the inserted x.
template <class InputIterator>
void
insert(InputIterator first, InputIterator last);
Inserts copies of the elements in the range [first, last].
key_compare
key_comp () const;
Returns the comparison function object for the set.
iterator
lower_bound (const key_type& x) const;
Returns an iterator that points to the first element that is greater than or equal to x. If there is no
such element, the iterator points to the past-the-end value.
size_type
max_size () const;
Returns size of the largest possible set.
size_type
size () const;
Returns the number of elements.
void
swap (set<Key, Compare, Allocator>& x);
Exchanges self with x.
iterator
upper_bound (const key_type& x) const