std::unordered_multimap<Key,T,Hash,KeyEqual,Allocator>::end, std::unordered_multimap<Key,T,Hash,KeyEqual,Allocator>::cend
Min standard notice:
Returns an iterator to the element following the last element of the unordered_multimap.
# Declarations
iterator end() noexcept;
(since C++11)
const_iterator end() const noexcept;
(since C++11)
const_iterator cend() const noexcept;
(since C++11)
# Return value
Iterator to the element following the last element.
# Example
#include <algorithm>
#include <cassert>
#include <iostream>
#include <string>
#include <utility>
#include <unordered_map>
int main()
{
auto show_node = [](const std::pair<std::string, std::string>& node)
{
std::cout << node.first << " : " << node.second << '\n';
};
std::unordered_multimap<std::string, std::string> lemmas;
assert(lemmas.begin() == lemmas.end());
assert(lemmas.cbegin() == lemmas.cend());
lemmas.insert({ "1. ∀x ∈ N ∃y ∈ N", "x ≤ y" });
show_node(*lemmas.cbegin());
assert(lemmas.begin() != lemmas.end());
assert(lemmas.cbegin() != lemmas.cend());
lemmas.begin()->second = "x < y";
show_node(*lemmas.cbegin());
lemmas.insert({ "2. ∀x, y ∈ N ", "x = y V x ≠ y" });
show_node(*lemmas.cbegin());
lemmas.insert({ "3. ∀x ∈ N ∃y ∈ N", "y = x + 1" });
show_node(*lemmas.cbegin());
std::cout << "Lemmas: \n";
std::for_each(lemmas.cbegin(), lemmas.cend(), [&](const auto& n)
{
show_node(n);
});
std::cout << '\n';
}