The
unordered_multimap::empty() is a built-in function in C++ STL which returns a boolean value. It returns true if the unordered_multimap container is empty. Otherwise, it returns false.
Syntax:
unordered_multimap_name.empty()
Parameters: The function does not accept any parameter.
Return Value: It returns a boolean value which denotes whether a unordered_multimap is empty or not.
Below programs illustrates the above function:
Program 1:
Output:
Key and Elements: {5:6} {3:4} {2:3} {1:2} {1:2}
Container is empty
Program 2: