C++ Maps
C++ Maps are sorted associative containers that contain unique key/value pairs. For example, you could create a map that associates a string with an integer, and then use that map to associate the number of days in each month with the name of each month.
Display all entries for C++ Maps on one page, or view entries individually:
Map constructors & destructors | default methods to allocate, copy, and deallocate maps |
Map operators | assign, compare, and access elements of a map |
begin | returns an iterator to the beginning of the map |
clear | removes all elements from the map |
count | returns the number of elements matching a certain key |
empty | true if the map has no elements |
end | returns an iterator just past the last element of a map |
equal_range | returns iterators to the first and just past the last elements matching a specific key |
erase | removes elements from a map |
find | returns an iterator to specific elements |
insert | insert items into a map |
key_comp | returns the function that compares keys |
lower_bound | returns an iterator to the first element greater than or equal to a certain value |
max_size | returns the maximum number of elements that the map can hold |
rbegin | returns a reverse_iterator to the end of the map |
rend | returns a reverse_iterator to the beginning of the map |
size | returns the number of items in the map |
swap | swap the contents of this map with another |
upper_bound | returns an iterator to the first element greater than a certain value |
value_comp | returns the function that compares values |