cpp/iterator/end

Returns an iterator to the end (i.e. the element after the last element) of the given range.

@1@ Returns exactly, which is typically an iterator one past the end of the sequence represented by. If is a standard, this returns a  when  is not const-qualified, and a  otherwise. @2@ Returns a pointer to the end of the array. @3@ Returns exactly, with always treated as const-qualified. If is a standard, this always returns a.

Return value
An iterator to the end of the range. Note that the end of a range is defined as the element following the last valid element.

Exceptions
@3@

Overloads
Custom overloads of may be provided for classes and enumerations that do not expose a suitable  member function, yet can be iterated. The following overloads are already provided by the standard library:

Similar to the use of (described in ), typical use of the  function in generic context is an equivalent of, which lets both the ADL-selected overloads for user-defined types and the standard library function templates to appear in the same overload set.