VOOZH about

URL: https://www.geeksforgeeks.org/cpp/unordered_multiset-empty-function-in-cstl/

⇱ unordered_multiset empty() function in C++STL - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

unordered_multiset empty() function in C++STL

Last Updated : 2 Aug, 2018
The unordered_multiset::empty() is a built-in function in C++ STL which returns a boolean value. It returns true if the unordered_multiset container is empty. Otherwise, it returns false. Syntax:
unordered_multiset_name.empty()
Parameters: The function does not accepts any parameter. Return Value: It returns a boolean value which denotes whether a unordered_multiset is empty or not. Below programs illustrates the above function: Program 1:
Output:
Elements: 14 11 11 11 12 13 13 
Container is empty
Program 2:
Output:
Elements: a a b c d d d 
Container is empty
Comment