C++ List pop_back()C++ List pop_back() function removes the last element from the list and reduces the size of the list by one. pop_back() function removes the last element i.e 4 SyntaxParameterIt does not contain any parameter. Return valueIt does not return any value. ExampleLet's see a simple example Output: 6,7 In this example, pop_back() function removes the last two elements from the list.
Next Topicpop_front() Function
|