4#ifndef TETL_ALGORITHM_NTH_ELEMENT_HPP
5#define TETL_ALGORITHM_NTH_ELEMENT_HPP
7#include <etl/_algorithm/sort.hpp>
8#include <etl/_utility/ignore_unused.hpp>
22template <
typename RandomIt,
typename Compare>
23constexpr auto nth_element(RandomIt first, RandomIt nth, RandomIt last, Compare comp) ->
void
26 etl::ignore_unused(nth);
27 etl::sort(first, last, comp);
30template <
typename RandomIt>
31constexpr auto nth_element(RandomIt first, RandomIt nth, RandomIt last) ->
void
33 etl::ignore_unused(nth);
34 etl::sort(first, last);
constexpr auto nth_element(RandomIt first, RandomIt nth, RandomIt last, Compare comp) -> void
nth_element is a partial sorting algorithm that rearranges elements in [first, last) such that:
Definition nth_element.hpp:23
Definition adjacent_find.hpp:9
constexpr auto nth_element(RandomIt first, RandomIt nth, RandomIt last) -> void
Definition nth_element.hpp:31