xte::array<T>::rend()

Defined in header <xte/data/array.hpp>


Definitions

#0
[[nodiscard]] constexpr auto rend(this auto&& self) noexcept;
With the same qualifiers as self, returns a reverse iterator pointing one past the first element. May return nullptr if there are no elements.

#1
[[nodiscard]] constexpr auto crend() const noexcept;
Same as #0 but const-qualified.



Example

xte::array array = { 1, 2, 3 };
for (auto iter = array.rbegin(); iter != array.rend(); ++iter) {
	std::println("{}", *iter);
}
Output:
3
2
1
[View in Compiler Explorer]