Expression  Return type  Assertion/note  Complexity 
pre/postcondition  
Key  compile time  
T  compile time  
Key  Requires: value_type is Cpp17Erasable from X  compile time  
X::value_type (unordered_map and unordered_multimap only)  pair<const Key, T>  Requires: value_type is Cpp17Erasable from X  compile time 
Hash  compile time  
Hash::transparent_key_equal if such a qualifiedid
is valid and denotes a type ([temp.deduct]);
otherwise, Pred.  Pred is an equivalence relation.  compile time  
An iterator type whose category, value type,
difference type, and pointer and reference types are the same as
X::iterator's.  A local_iterator object may be used to iterate through a
single bucket, but may not be used to iterate across
buckets.  compile time  
An iterator type whose category, value type,
difference type, and pointer and reference types are the same as
X::const_iterator's.  A const_local_iterator object may be used to iterate through a
single bucket, but may not be used to iterate across
buckets.  compile time  
a specialization of a nodehandle
class template, such that the public nested types are
the same types as the corresponding types in X.  see [container.node]  compile time  
X  Effects: Constructs an empty container with at least n buckets,
using hf as the hash function and eq as the key
equality predicate.  
X(n, hf) X a(n, hf);  X  Effects: Constructs an empty container with at least n buckets, using hf as the hash function and key_equal() as the key equality predicate.  
X(n) X a(n);  X  Effects: Constructs an empty container with at least n buckets, using hasher() as the hash function and key_equal() as the key equality predicate.  
X() X a;  X  Effects: Constructs an empty container with an unspecified number of buckets, using hasher() as the hash function and key_equal() as the key equality predicate.  constant 
X(i, j, n, hf, eq) X a(i, j, n, hf, eq);  X  Effects: Constructs an empty container with at least n buckets, using hf as the hash function and eq as the key equality predicate, and inserts elements from [i, j) into it.  Average case (N is distance(i, j)), worst case

X(i, j, n, hf) X a(i, j, n, hf);  X  Effects: Constructs an empty container with at least n buckets, using hf as the hash function and key_equal() as the key equality predicate, and inserts elements from [i, j) into it.  Average case (N is distance(i, j)), worst case

X(i, j, n) X a(i, j, n);  X  Effects: Constructs an empty container with at least n buckets, using hasher() as the hash function and key_equal() as the key equality predicate, and inserts elements from [i, j) into it.  Average case (N is distance(i, j)), worst case

X(i, j) X a(i, j);  X  Effects: Constructs an empty container with an unspecified number of buckets, using hasher() as the hash function and key_equal() as the key equality predicate, and inserts elements from [i, j) into it.  Average case (N is distance(i, j)), worst case

X(il)  X  Same as X(il.begin(), il.end()).  
X(il, n)  X  Same as X(il.begin(), il.end(), n).  
X(il, n, hf)  X  Same as X(il.begin(), il.end(), n, hf).  
X(il, n, hf, eq)  X  Same as X(il.begin(), il.end(), n, hf, eq).  
X(b) X a(b);  X  Copy constructor.  Average case linear in b.size(), worst case quadratic. 
a = b  X&  Copy assignment operator.  Average case linear in b.size(), worst case quadratic. 
a = il  X&  All
existing elements of a are either assigned to or destroyed.  Same as a = X(il). 
hasher  Returns b's hash function.  constant  
key_equal  Returns b's key equality predicate.  constant  
pair<iterator, bool>  Effects: Inserts a value_type object t constructed with std::forward<Args>(args)... if and only if there is no element in the container with key equivalent to the key of t. The bool component of the returned
pair is true if and only if the insertion takes place, and the iterator
component of the pair points to the element with key equivalent to the
key of t.  
a_eq.emplace(args)  iterator  Effects: Inserts a value_type object t constructed with std::forward<Args>(args)... and returns the iterator pointing to the newly inserted element.  
iterator  Return value is an iterator pointing to the element with the key equivalent
to the newly inserted element. Implementations are
permitted to ignore the hint.  
pair<iterator, bool>  Requires: If t is a nonconst rvalue, value_type shall be
Cpp17MoveInsertable into X; otherwise, value_type shall be
Cpp17CopyInsertable into X. Effects: Inserts t if and only if there is no element in the container with key equivalent to the key of t. The bool
component of the returned pair indicates whether the insertion
takes place, and the iterator component points to the element
with key equivalent to the key of t.  
a_eq.insert(t)  iterator  Requires: If t is a nonconst rvalue, value_type shall be
Cpp17MoveInsertable into X; otherwise, value_type shall be
Cpp17CopyInsertable into X.  
a.insert(p, t)  iterator  Requires: If t is a nonconst rvalue, value_type shall be
Cpp17MoveInsertable into X; otherwise, value_type shall be
Cpp17CopyInsertable into X. Return value is an iterator pointing
to the element with the key equivalent to that of t. The
iterator p is a hint pointing to where the search should
start. Implementations are permitted to ignore the hint.  
a.insert(i, j)  void  Worst case .  
a.insert(il)  void  Same as a.insert(il.begin(), il.end()).  
a_uniq. insert(nh)  insert_return_type  Otherwise, inserts the
element owned by nh if and only if there is no element in the
container with a key equivalent to nh.key(). Otherwise if the insertion took place, inserted is true,
position points to the inserted element, and node is empty;
if the insertion failed, inserted is false,
node has the previous value of nh, and position
points to an element with a key equivalent to nh.key().  
a_eq. insert(nh)  iterator  Otherwise, inserts the element owned by nh and returns an iterator
pointing to the newly inserted element.  
a.insert(q, nh)  iterator  Otherwise, inserts the element owned by nh if and only if there
is no element with key equivalent to nh.key() in containers with
unique keys; always inserts the element owned by nh in containers
with equivalent keys. Always returns the iterator pointing to the element
with key equivalent to nh.key(). The iterator q is a hint
pointing to where the search should start. Implementations are permitted
to ignore the hint.  
node_type  Removes an element in the container with key equivalent to k.  
a.extract(q)  node_type  Removes the element pointed to by q. Returns a node_type owning that element.  
void  Attempts to extract each element in a2 and insert it into a using the hash function and key equality predicate of a. In containers with unique keys, if there is an element in a with
key equivalent to the key of an element from a2, then that
element is not extracted from a2.
Ensures: Pointers and references to the transferred elements of a2
refer to those same elements but as members of a. Iterators referring
to the transferred elements and all iterators referring to a will
be invalidated, but iterators to elements remaining in a2 will
remain valid.  Worst case .  
size_type  Erases all elements with key equivalent to k. Returns
the number of elements erased.  Average case . Worst case
.  
a.erase(q)  iterator  Erases the element pointed to by q. Returns the
iterator immediately following q prior to the erasure.  
a.erase(r)  iterator  Erases the element pointed to by r. Returns the
iterator immediately following r prior to the erasure.  
a.erase(q1, q2)  iterator  Returns
the iterator immediately following the erased elements prior to the
erasure.  
void  Erases all elements in the container. Ensures: a.empty() returns true  Linear in a.size().  
Returns an iterator pointing to an element with key equivalent to
k, or b.end() if no such element exists.  
a_tran.find(ke)  Returns an iterator pointing to an element with key equivalent to
ke, or a_tran.end() if no such element exists.  
size_type  Returns the number of elements with key equivalent to k.  
a_tran.count(ke)  size_type  Returns the number of elements with key equivalent to ke.  
bool  Equivalent to b.find(k) != b.end()  
a_tran.contains(ke)  bool  Equivalent to a_tran.find(ke) != a_tran.end()  
Returns a range containing all elements with keys equivalent to
k. Returns make_pair(b.end(), b.end()) if
no such elements exist.  Average case . Worst case
.  
a_tran.equal_range(ke)  Returns a range containing all elements with keys equivalent to
ke. Returns make_pair(a_tran.end(), a_tran.end()) if
no such elements exist.  Average case
. Worst case .  
size_type  Returns the number of buckets that b contains.  Constant  
size_type  Returns an upper bound on the number of buckets that b might
ever contain.  Constant  
size_type  Returns the index of the bucket in which elements with keys equivalent to k would be found, if any such element existed.  Constant  
size_type  Returns the number of elements in the bucket.  
b.begin(n) returns an iterator referring to the
first element in the bucket. If the bucket is empty, then
b.begin(n) == b.end(n).  Constant  
b.end(n) returns an iterator which is the pasttheend
value for the bucket.  Constant  
const_local_iterator  b.cbegin(n) returns an iterator referring to the
first element in the bucket. If the bucket is empty, then
b.cbegin(n) == b.cend(n).  Constant  
const_local_iterator  b.cend(n) returns an iterator which is the pasttheend
value for the bucket.  Constant  
float  Returns the average number of elements per bucket.  Constant  
float  Returns a positive number that the container attempts to keep the load factor
less than or equal to. The container automatically increases the
number of buckets as necessary to keep the load factor below this
number.  Constant  
a.max_load_factor(z)  void  May change the container's maximum load factor, using z as a hint.  Constant 
void  Average case linear in a.size(), worst case quadratic.  
void  Average case linear in a.size(), worst case quadratic. 