Skip to content

Search topics & cppreference

Search all study topics, concept maps, and 6,587 C++ and C reference pages.

std::ranges::subrange<I,S,K>::empty

Checks whether the subrange is empty.

Ranges
  • C++17
  • C++20
1 min readView on cppreference
NotebookLM
constexpr bool empty() const;
(since C++20)

Checks whether the subrange is empty.

Return value

begin_ == end_.

Example

This section is incomplete
Reason: no example

See also

obtains the size of the subrange
(public member function)
(C++17)
checks whether the container is empty
(function template)
checks whether a range is empty
(customization point object)

Content from this page on cppreference.com, licensed under CC-BY-SA 3.0 and GFDL. Modified: restyled, site navigation removed, code windows added. Offline snapshot of 9 February 2025.