Multimap operators [C++ Reference]
Keywords: stl,multimap,multimap_operators
Date: 2008-10-14T15:42:07-0700

[[Multimap operators]]
C++ Reference
Translations of this page?:

- en
- br-pt
- cn
- fr
- it
- jp
- pl
- ru
- tr

## Multimap operators

Syntax:

        #include <map>
        multimap operator=(const multimap& c2);
        bool operator==(const multimap& c1, const multimap& c2);
        bool operator!=(const multimap& c1, const multimap& c2);
        bool operator<(const multimap& c1, const multimap& c2);
        bool operator>(const multimap& c1, const multimap& c2);
        bool operator<=(const multimap& c1, const multimap& c2);
        bool operator>=(const multimap& c1, const multimap& c2);

All of the C++ containers can be compared and assigned with the standard comparison operators: ==, !=, ⇐, >=, <, >, and =. Performing a comparison or assigning one multimap to another takes linear time.

Two multimaps are equal if:

1. Their size is the same, and
2. Each member in location i in one multimap is equal to the the member in location i in the other multimap.

Comparisons among multimaps are done lexicographically.

Related Topics: Multimap constructors & destructors

Edit this page • Old revisions
• • • Login • Index • Recent changes • RSS • cc •