std::basic_string::back

From Cppreference

Jump to: navigation, search
CharT& back();
(C++11 feature)
const CharT& back() const;
(C++11 feature)

Returns reference to the last character in the string.

Contents

[edit] Parameters

(none)

[edit] Return value

reference to the last character.

[edit] Complexity

Constant

[edit] See also

front (C++11)
accesses the first character
(public member function)