Scroll to navigation

std::queue::back(3) C++ Standard Libary std::queue::back(3)

NAME

std::queue::back - std::queue::back

Synopsis

reference back(); const_reference back() const;

Returns reference to the last element in the queue. This is the most recently pushed element. Effectively calls c.back().

Parameters

(none)

Return value

Reference to the last element.

Complexity

Constant.

See also

front access the first element
(public member function) push inserts element at the end
(public member function)

2026.11.10 http://cppreference.com