Range-v3 Range algorithms, views, and actions for the Standard Library |

Typedefs | Functions
Algorithms

## Description

Iterator- and range-based algorithms, like the standard algorithms.

## Typedefs
template<typename I1 , typename I2 , typename O >
using | ranges::binary_transform_result = detail::in1_in2_out_result< I1, I2, O >
template<typename I , typename O >
using | ranges::copy_backward_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::copy_if_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::copy_n_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::copy_result = detail::in_out_result< I, O >
template<typename I , typename F >
using | ranges::for_each_result = detail::in_fun_result< I, F >
template<typename O , typename F >
using | ranges::generate_n_result = detail::out_fun_result< O, F >
template<typename O , typename F >
using | ranges::generate_result = detail::out_fun_result< O, F >
template<typename I0 , typename I1 , typename O >
using | ranges::merge_result = detail::in1_in2_out_result< I0, I1, O >
template<typename I >
using | ranges::minmax_element_result = detail::min_max_result< I, I >
template<typename T >
using | ranges::minmax_result = detail::min_max_result< T, T >
template<typename I1 , typename I2 >
using | ranges::mismatch_result = detail::in1_in2_result< I1, I2 >
template<typename I , typename O >
using | ranges::move_backward_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::move_result = detail::in_out_result< I, O >
template<typename I , typename O0 , typename O1 >
using | ranges::partition_copy_result = detail::in_out1_out2_result< I, O0, O1 >
template<typename I , typename O >
using | ranges::remove_copy_if_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::remove_copy_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::replace_copy_if_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::replace_copy_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::reverse_copy_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::rotate_copy_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::sample_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::set_difference_result = detail::in1_out_result< I, O >
template<typename I1 , typename I2 , typename O >
using | ranges::set_symmetric_difference_result = detail::in1_in2_out_result< I1, I2, O >
template<typename I1 , typename I2 , typename O >
using | ranges::set_union_result = detail::in1_in2_out_result< I1, I2, O >
template<typename I1 , typename I2 >
using | ranges::swap_ranges_result = detail::in1_in2_result< I1, I2 >
template<typename I , typename O >
using | ranges::unary_transform_result = detail::in_out_result< I, O >
template<typename I , typename O >
using | ranges::unique_copy_result = detail::in_out_result< I, O >

## Functions
template<typename I , typename S , typename C = equal_to, typename P = identity>
I | ranges::adjacent_find (I first, S last, C pred=C{}, P proj=P{})
| function template `adjacent_find` More...
template<typename Rng , typename C = equal_to, typename P = identity>
borrowed_iterator_t< Rng > | ranges::adjacent_find (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename Pred , typename Proj = identity>
I | ranges::adjacent_remove_if (I first, S last, Pred pred={}, Proj proj={})
| function `adjacent_remove_if` More...
template<typename Rng , typename Pred , typename Proj = identity>
borrowed_iterator_t< Rng > | ranges::adjacent_remove_if (Rng &&rng, Pred pred, Proj proj={})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename F , typename P = identity>
bool | ranges::all_of (I first, S last, F pred, P proj=P{})
| function template `all_of` More...
template<typename Rng , typename F , typename P = identity>
bool | ranges::all_of (Rng &&rng, F pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename F , typename P = identity>
bool | ranges::any_of (I first, S last, F pred, P proj=P{})
| function template `any_of` More...
template<typename Rng , typename F , typename P = identity>
bool | ranges::any_of (Rng &&rng, F pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename V , typename C = less, typename P = identity>
bool | ranges::binary_search (I first, S last, V const &val, C pred=C{}, P proj=P{})
| function template `binary_search` More...
template<typename Rng , typename V , typename C = less, typename P = identity>
bool | ranges::binary_search (Rng &&rng, V const &val, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename T , typename P = identity>
constexpr bool | ranges::contains (I first, S last, const T &val, P proj={})
| function template `contains` More...
template<typename Rng , typename T , typename P = identity>
constexpr bool | ranges::contains (Rng &&rng, const T &val, P proj={})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O >
constexpr copy_result< I, O > | ranges::copy (I first, S last, O out)
| function template `copy` More...
template<typename Rng , typename O >
constexpr copy_result< borrowed_iterator_t< Rng >, O > | ranges::copy (Rng &&rng, O out)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O >
copy_backward_result< I, O > | ranges::copy_backward (I first, S end_, O out)
| function template `copy_backward` More...
template<typename Rng , typename O >
copy_backward_result< borrowed_iterator_t< Rng >, O > | ranges::copy_backward (Rng &&rng, O out)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O , typename F , typename P = identity>
copy_if_result< I, O > | ranges::copy_if (I first, S last, O out, F pred, P proj=P{})
| function template `copy_if` More...
template<typename Rng , typename O , typename F , typename P = identity>
copy_if_result< borrowed_iterator_t< Rng >, O > | ranges::copy_if (Rng &&rng, O out, F pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename O , typename P = identity>
copy_n_result< I, O > | ranges::copy_n (I first, iter_difference_t< I > n, O out)
| function template `copy_n` More...
template<typename I , typename S , typename V , typename P = identity>
iter_difference_t< I > | ranges::count (I first, S last, V const &val, P proj=P{})
| function template `count` More...
template<typename Rng , typename V , typename P = identity>
iter_difference_t< iterator_t< Rng > > | ranges::count (Rng &&rng, V const &val, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename R , typename P = identity>
iter_difference_t< I > | ranges::count_if (I first, S last, R pred, P proj=P{})
| function template `count_if` More...
template<typename Rng , typename R , typename P = identity>
iter_difference_t< iterator_t< Rng > > | ranges::count_if (Rng &&rng, R pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I0 , typename S0 , typename I1 , typename S1 , typename C = equal_to, typename P0 = identity, typename P1 = identity>
constexpr bool | ranges::ends_with (I0 begin0, S0 end0, I1 begin1, S1 end1, C pred=C{}, P0 proj0=P0{}, P1 proj1=P1{})
| function template `ends_with` More...
template<typename Rng0 , typename Rng1 , typename C = equal_to, typename P0 = identity, typename P1 = identity>
constexpr bool | ranges::ends_with (Rng0 &&rng0, Rng1 &&rng1, C pred=C{}, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I0 , typename S0 , typename I1 , typename C = equal_to, typename P0 = identity, typename P1 = identity>
constexpr bool | ranges::equal (I0 begin0, S0 end0, I1 begin1, C pred=C{}, P0 proj0=P0{}, P1 proj1=P1{})
| function template `equal` More...
template<typename I0 , typename S0 , typename I1 , typename S1 , typename C = equal_to, typename P0 = identity, typename P1 = identity>
constexpr bool | ranges::equal (I0 begin0, S0 end0, I1 begin1, S1 end1, C pred=C{}, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng0 , typename I1Ref , typename C = equal_to, typename P0 = identity, typename P1 = identity>
constexpr bool | ranges::equal (Rng0 &&rng0, I1Ref &&begin1, C pred=C{}, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng0 , typename Rng1 , typename C = equal_to, typename P0 = identity, typename P1 = identity>
constexpr bool | ranges::equal (Rng0 &&rng0, Rng1 &&rng1, C pred=C{}, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename V , typename C = less, typename P = identity>
subrange< I > | ranges::equal_range (I first, S last, V const &val, C pred=C{}, P proj=P{})
| function template `equal_range` More...
template<typename Rng , typename V , typename C = less, typename P = identity>
borrowed_subrange_t< Rng > | ranges::equal_range (Rng &&rng, V const &val, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename O , typename S , typename V >
O | ranges::fill (O first, S last, V const &val)
| function template `fill` More...
template<typename Rng , typename V >
borrowed_iterator_t< Rng > | ranges::fill (Rng &&rng, V const &val)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename O , typename V >
O | ranges::fill_n (O first, iter_difference_t< O > n, V const &val)
| function template `equal` More...
template<typename I , typename S , typename V , typename P = identity>
constexpr I | ranges::find (I first, S last, V const &val, P proj=P{})
| template function `find` More...
template<typename Rng , typename V , typename P = identity>
constexpr borrowed_iterator_t< Rng > | ranges::find (Rng &&rng, V const &val, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I1 , typename S1 , typename I2 , typename S2 , typename R = equal_to, typename P = identity>
subrange< I1 > | ranges::find_end (I1 begin1, S1 end1, I2 begin2, S2 end2, R pred=R{}, P proj=P{})
| function template `find_end` More...
template<typename Rng1 , typename Rng2 , typename R = equal_to, typename P = identity>
borrowed_subrange_t< Rng1 > | ranges::find_end (Rng1 &&rng1, Rng2 &&rng2, R pred=R{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I0 , typename S0 , typename I1 , typename S1 , typename R = equal_to, typename P0 = identity, typename P1 = identity>
constexpr I0 | ranges::find_first_of (I0 begin0, S0 end0, I1 begin1, S1 end1, R pred=R{}, P0 proj0=P0{}, P1 proj1=P1{})
| function template `find_first_of` More...
template<typename Rng0 , typename Rng1 , typename R = equal_to, typename P0 = identity, typename P1 = identity>
constexpr borrowed_iterator_t< Rng0 > | ranges::find_first_of (Rng0 &&rng0, Rng1 &&rng1, R pred=R{}, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename F , typename P = identity>
I | ranges::find_if (I first, S last, F pred, P proj=P{})
| template function `find` More...
template<typename Rng , typename F , typename P = identity>
borrowed_iterator_t< Rng > | ranges::find_if (Rng &&rng, F pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename F , typename P = identity>
I | ranges::find_if_not (I first, S last, F pred, P proj=P{})
| template function `find_if_not` More...
template<typename Rng , typename F , typename P = identity>
borrowed_iterator_t< Rng > | ranges::find_if_not (Rng &&rng, F pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename F , typename P = identity>
for_each_result< I, F > | ranges::for_each (I first, S last, F fun, P proj=P{})
| function template `for_each` More...
template<typename Rng , typename F , typename P = identity>
for_each_result< borrowed_iterator_t< Rng >, F > | ranges::for_each (Rng &&rng, F fun, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename F , typename P = identity>
I | ranges::for_each_n (I first, iter_difference_t< I > n, F fun, P proj=P{})
| function template `for_each_n` More...
template<typename Rng , typename F , typename P = identity>
borrowed_iterator_t< Rng > | ranges::for_each_n (Rng &&rng, range_difference_t< Rng > n, F fun, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename O , typename S , typename F >
generate_result< O, F > | ranges::generate (O first, S last, F fun)
| function template `generate_n` More...
template<typename Rng , typename F >
generate_result< borrowed_iterator_t< Rng >, F > | ranges::generate (Rng &&rng, F fun)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename O , typename F >
generate_n_result< O, F > | ranges::generate_n (O first, iter_difference_t< O > n, F fun)
| function template `generate_n` More...
template<typename I1 , typename S1 , typename I2 , typename S2 , typename C = less, typename P1 = identity, typename P2 = identity>
bool | ranges::includes (I1 begin1, S1 end1, I2 begin2, S2 end2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| function template `includes` More...
template<typename Rng1 , typename Rng2 , typename C = less, typename P1 = identity, typename P2 = identity>
bool | ranges::includes (Rng1 &&rng1, Rng2 &&rng2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::inplace_merge (I first, I middle, S last, C pred=C{}, P proj=P{})
| function template `inplace_merge` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::inplace_merge (Rng &&rng, iterator_t< Rng > middle, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
bool | ranges::is_heap (I first, S last, C pred=C{}, P proj=P{})
| function template `is_heap` More...
template<typename Rng , typename C = less, typename P = identity>
bool | ranges::is_heap (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::is_heap_until (I first, S last, C pred=C{}, P proj=P{})
| function template `is_heap_until` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::is_heap_until (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C , typename P = identity>
bool | ranges::is_partitioned (I first, S last, C pred, P proj=P{})
| function template `is_partitioned` More...
template<typename Rng , typename C , typename P = identity>
bool | ranges::is_partitioned (Rng &&rng, C pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I1 , typename S1 , typename I2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>
bool | ranges::is_permutation (I1 begin1, S1 end1, I2 begin2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| function template `is_permutation` More...
template<typename I1 , typename S1 , typename I2 , typename S2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>
bool | ranges::is_permutation (I1 begin1, S1 end1, I2 begin2, S2 end2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng1 , typename I2Ref , typename C = equal_to, typename P1 = identity, typename P2 = identity>
bool | ranges::is_permutation (Rng1 &&rng1, I2Ref &&begin2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng1 , typename Rng2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>
bool | ranges::is_permutation (Rng1 &&rng1, Rng2 &&rng2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename R = less, typename P = identity>
bool | ranges::is_sorted (I first, S last, R rel=R{}, P proj=P{})
| template function `is_sorted` More...
template<typename Rng , typename R = less, typename P = identity>
bool | ranges::is_sorted (Rng &&rng, R rel=R{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename R = less, typename P = identity>
I | ranges::is_sorted_until (I first, S last, R pred=R{}, P proj=P{})
| template function `is_sorted_until` More...
template<typename Rng , typename R = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::is_sorted_until (Rng &&rng, R pred=R{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I0 , typename S0 , typename I1 , typename S1 , typename C = less, typename P0 = identity, typename P1 = identity>
bool | ranges::lexicographical_compare (I0 begin0, S0 end0, I1 begin1, S1 end1, C pred=C{}, P0 proj0=P0{}, P1 proj1=P1{})
| function template `lexicographical_compare` More...
template<typename Rng0 , typename Rng1 , typename C = less, typename P0 = identity, typename P1 = identity>
bool | ranges::lexicographical_compare (Rng0 &&rng0, Rng1 &&rng1, C pred=C{}, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename V , typename C = less, typename P = identity>
I | ranges::lower_bound (I first, S last, V const &val, C pred=C{}, P proj=P{})
| function template `lower_bound` More...
template<typename Rng , typename V , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::lower_bound (Rng &&rng, V const &val, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::make_heap (I first, S last, C pred=C{}, P proj=P{})
| function template `make_heap` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::make_heap (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng , typename C = less, typename P = identity>
constexpr range_value_t< Rng > | ranges::max (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename T , typename C = less, typename P = identity>
constexpr T | ranges::max (std::initializer_list< T > const &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename T , typename C = less, typename P = identity>
constexpr T const & | ranges::max (T const &a, T const &b, C pred=C{}, P proj=P{})
| function template `max` More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::max_element (I first, S last, C pred=C{}, P proj=P{})
| function template `max_element` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::max_element (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I0 , typename S0 , typename I1 , typename S1 , typename O , typename C = less, typename P0 = identity, typename P1 = identity>
merge_result< I0, I1, O > | ranges::merge (I0 begin0, S0 end0, I1 begin1, S1 end1, O out, C pred=C{}, P0 proj0=P0{}, P1 proj1=P1{})
| function template `merge` More...
template<typename Rng0 , typename Rng1 , typename O , typename C = less, typename P0 = identity, typename P1 = identity>
merge_result< borrowed_iterator_t< Rng0 >, borrowed_iterator_t< Rng1 >, O > | ranges::merge (Rng0 &&rng0, Rng1 &&rng1, O out, C pred=C{}, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng , typename C = less, typename P = identity>
constexpr range_value_t< Rng > | ranges::min (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename T , typename C = less, typename P = identity>
constexpr T | ranges::min (std::initializer_list< T > const &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename T , typename C = less, typename P = identity>
constexpr T const & | ranges::min (T const &a, T const &b, C pred=C{}, P proj=P{})
| function template `min` More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::min_element (I first, S last, C pred=C{}, P proj=P{})
| function template `min_element` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::min_element (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng , typename C = less, typename P = identity>
constexpr minmax_result< range_value_t< Rng > > | ranges::minmax (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename T , typename C = less, typename P = identity>
constexpr minmax_result< T > | ranges::minmax (std::initializer_list< T > const &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename T , typename C = less, typename P = identity>
constexpr minmax_result< T const & > | ranges::minmax (T const &a, T const &b, C pred=C{}, P proj=P{})
| function template `minmax` More...
template<typename I , typename S , typename C = less, typename P = identity>
minmax_element_result< I > | ranges::minmax_element (I first, S last, C pred=C{}, P proj=P{})
| function template `minmax_element` More...
template<typename Rng , typename C = less, typename P = identity>
minmax_element_result< borrowed_iterator_t< Rng > > | ranges::minmax_element (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I1 , typename S1 , typename I2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>
mismatch_result< I1, I2 > | ranges::mismatch (I1 begin1, S1 end1, I2 begin2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| function template `mismatch` More...
template<typename I1 , typename S1 , typename I2 , typename S2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>
mismatch_result< I1, I2 > | ranges::mismatch (I1 begin1, S1 end1, I2 begin2, S2 end2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng1 , typename I2Ref , typename C = equal_to, typename P1 = identity, typename P2 = identity>
mismatch_result< borrowed_iterator_t< Rng1 >, uncvref_t< I2Ref > > | ranges::mismatch (Rng1 &&rng1, I2Ref &&begin2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
template<typename Rng1 , typename Rng2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>
mismatch_result< borrowed_iterator_t< Rng1 >, borrowed_iterator_t< Rng2 > > | ranges::mismatch (Rng1 &&rng1, Rng2 &&rng2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O >
move_result< I, O > | ranges::move (I first, S last, O out)
| function template `move` More...
template<typename Rng , typename O >
move_result< borrowed_iterator_t< Rng >, O > | ranges::move (Rng &&rng, O out)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O >
move_backward_result< I, O > | ranges::move_backward (I first, S end_, O out)
| function template `move_backward` More...
template<typename Rng , typename O >
move_backward_result< borrowed_iterator_t< Rng >, O > | ranges::move_backward (Rng &&rng, O out)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
bool | ranges::next_permutation (I first, S end_, C pred=C{}, P proj=P{})
| function template `next_permutation` More...
template<typename Rng , typename C = less, typename P = identity>
bool | ranges::next_permutation (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename F , typename P = identity>
bool | ranges::none_of (I first, S last, F pred, P proj=P{})
| function template `none_of` More...
template<typename Rng , typename F , typename P = identity>
bool | ranges::none_of (Rng &&rng, F pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::nth_element (I first, I nth, S end_, C pred=C{}, P proj=P{})
| function template `nth_element` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::nth_element (Rng &&rng, iterator_t< Rng > nth, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::partial_sort (I first, I middle, S last, C pred=C{}, P proj=P{})
| function template `partial_sort` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::partial_sort (Rng &&rng, iterator_t< Rng > middle, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename SI , typename O , typename SO , typename C = less, typename PI = identity, typename PO = identity>
O | ranges::partial_sort_copy (I first, SI last, O out_begin, SO out_end, C pred=C{}, PI in_proj=PI{}, PO out_proj=PO{})
| function template `partial_sort_copy` More...
template<typename InRng , typename OutRng , typename C = less, typename PI = identity, typename PO = identity>
borrowed_iterator_t< OutRng > | ranges::partial_sort_copy (InRng &&in_rng, OutRng &&out_rng, C pred=C{}, PI in_proj=PI{}, PO out_proj=PO{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C , typename P = identity>
I | ranges::partition (I first, S last, C pred, P proj=P{})
| function template `partition` More...
template<typename Rng , typename C , typename P = identity>
borrowed_iterator_t< Rng > | ranges::partition (Rng &&rng, C pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O0 , typename O1 , typename C , typename P = identity>
partition_copy_result< I, O0, O1 > | ranges::partition_copy (I first, S last, O0 o0, O1 o1, C pred, P proj=P{})
| function template `partition_copy` More...
template<typename Rng , typename O0 , typename O1 , typename C , typename P = identity>
partition_copy_result< borrowed_iterator_t< Rng >, O0, O1 > | ranges::partition_copy (Rng &&rng, O0 o0, O1 o1, C pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C , typename P = identity>
I | ranges::partition_point (I first, S last, C pred, P proj=P{})
| function template `partition_point` More...
template<typename Rng , typename C , typename P = identity>
borrowed_iterator_t< Rng > | ranges::partition_point (Rng &&rng, C pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::pop_heap (I first, S last, C pred=C{}, P proj=P{})
| function template `pop_heap` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::pop_heap (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
bool | ranges::prev_permutation (I first, S end_, C pred=C{}, P proj=P{})
| function template `prev_permutation` More...
template<typename Rng , typename C = less, typename P = identity>
bool | ranges::prev_permutation (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::push_heap (I first, S last, C pred=C{}, P proj=P{})
| function template `push_heap` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::push_heap (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename T , typename P = identity>
I | ranges::remove (I first, S last, T const &val, P proj=P{})
| function template `remove` More...
template<typename Rng , typename T , typename P = identity>
borrowed_iterator_t< Rng > | ranges::remove (Rng &&rng, T const &val, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O , typename T , typename P = identity>
remove_copy_result< I, O > | ranges::remove_copy (I first, S last, O out, T const &val, P proj=P{})
| function template `remove_copy` More...
template<typename Rng , typename O , typename T , typename P = identity>
remove_copy_result< borrowed_iterator_t< Rng >, O > | ranges::remove_copy (Rng &&rng, O out, T const &val, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O , typename C , typename P = identity>
remove_copy_if_result< I, O > | ranges::remove_copy_if (I first, S last, O out, C pred, P proj=P{})
| function template `remove_copy_if` More...
template<typename Rng , typename O , typename C , typename P = identity>
remove_copy_if_result< borrowed_iterator_t< Rng >, O > | ranges::remove_copy_if (Rng &&rng, O out, C pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C , typename P = identity>
I | ranges::remove_if (I first, S last, C pred, P proj=P{})
| function template `remove_if` More...
template<typename Rng , typename C , typename P = identity>
borrowed_iterator_t< Rng > | ranges::remove_if (Rng &&rng, C pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename T1 , typename T2 , typename P = identity>
I | ranges::replace (I first, S last, T1 const &old_value, T2 const &new_value, P proj={})
| function template `replace` More...
template<typename Rng , typename T1 , typename T2 , typename P = identity>
borrowed_iterator_t< Rng > | ranges::replace (Rng &&rng, T1 const &old_value, T2 const &new_value, P proj={})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O , typename T1 , typename T2 , typename P = identity>
replace_copy_result< I, O > | ranges::replace_copy (I first, S last, O out, T1 const &old_value, T2 const &new_value, P proj={})
| function template `replace_copy` More...
template<typename Rng , typename O , typename T1 , typename T2 , typename P = identity>
replace_copy_result< borrowed_iterator_t< Rng >, O > | ranges::replace_copy (Rng &&rng, O out, T1 const &old_value, T2 const &new_value, P proj={})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O , typename C , typename T , typename P = identity>
replace_copy_if_result< I, O > | ranges::replace_copy_if (I first, S last, O out, C pred, T const &new_value, P proj={})
| function template `replace_copy_if` More...
template<typename Rng , typename O , typename C , typename T , typename P = identity>
replace_copy_if_result< borrowed_iterator_t< Rng >, O > | ranges::replace_copy_if (Rng &&rng, O out, C pred, T const &new_value, P proj={})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C , typename T , typename P = identity>
I | ranges::replace_if (I first, S last, C pred, T const &new_value, P proj=P{})
| function template `replace_if` More...
template<typename Rng , typename C , typename T , typename P = identity>
borrowed_iterator_t< Rng > | ranges::replace_if (Rng &&rng, C pred, T const &new_value, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S >
I | ranges::reverse (I first, S end_)
| function template `reverse` More...
template<typename Rng , typename I = iterator_t<Rng>>
borrowed_iterator_t< Rng > | ranges::reverse (Rng &&rng)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O >
reverse_copy_result< I, O > | ranges::reverse_copy (I first, S end_, O out)
| function template `reverse_copy` More...
template<typename Rng , typename O >
reverse_copy_result< borrowed_iterator_t< Rng >, O > | ranges::reverse_copy (Rng &&rng, O out)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S >
subrange< I > | ranges::rotate (I first, I middle, S last)
| function template `rotate` More...
template<typename Rng , typename I = iterator_t<Rng>>
borrowed_subrange_t< Rng > | ranges::rotate (Rng &&rng, I middle)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O , typename P = identity>
rotate_copy_result< I, O > | ranges::rotate_copy (I first, I middle, S last, O out)
| function template `rotate_copy` More...
template<typename Rng , typename O , typename P = identity>
rotate_copy_result< borrowed_iterator_t< Rng >, O > | ranges::rotate_copy (Rng &&rng, iterator_t< Rng > middle, O out)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O , typename Gen = detail::default_random_engine &>
sample_result< I, O > | ranges::sample (I first, S last, O out, iter_difference_t< O > const n, Gen &&gen=detail::get_random_engine())
| function template `sample` More...
template<typename I , typename S , typename ORng , typename Gen = detail::default_random_engine &>
sample_result< I, borrowed_iterator_t< ORng > > | ranges::sample (I first, S last, ORng &&out, Gen &&gen=detail::get_random_engine())
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename IRng , typename ORng , typename Gen = detail::default_random_engine &>
sample_result< borrowed_iterator_t< IRng >, borrowed_iterator_t< ORng > > | ranges::sample (IRng &&rng, ORng &&out, Gen &&gen=detail::get_random_engine())
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng , typename O , typename Gen = detail::default_random_engine &>
sample_result< borrowed_iterator_t< Rng >, O > | ranges::sample (Rng &&rng, O out, iter_difference_t< O > const n, Gen &&gen=detail::get_random_engine())
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I1 , typename S1 , typename I2 , typename S2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>
subrange< I1 > | ranges::search (I1 begin1, S1 end1, I2 begin2, S2 end2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| function template `search` More...
template<typename Rng1 , typename Rng2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>
borrowed_subrange_t< Rng1 > | ranges::search (Rng1 &&rng1, Rng2 &&rng2, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename V , typename C = equal_to, typename P = identity>
subrange< I > | ranges::search_n (I first, S last, iter_difference_t< I > cnt, V const &val, C pred=C{}, P proj=P{})
| function template `search_n` More...
template<typename Rng , typename V , typename C = equal_to, typename P = identity>
borrowed_subrange_t< Rng > | ranges::search_n (Rng &&rng, iter_difference_t< iterator_t< Rng >> cnt, V const &val, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I1 , typename S1 , typename I2 , typename S2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>
set_difference_result< I1, O > | ranges::set_difference (I1 begin1, S1 end1, I2 begin2, S2 end2, O out, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| function template `set_difference` More...
template<typename Rng1 , typename Rng2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>
set_difference_result< borrowed_iterator_t< Rng1 >, O > | ranges::set_difference (Rng1 &&rng1, Rng2 &&rng2, O out, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I1 , typename S1 , typename I2 , typename S2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>
O | ranges::set_intersection (I1 begin1, S1 end1, I2 begin2, S2 end2, O out, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| function template `set_intersection` More...
template<typename Rng1 , typename Rng2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>
O | ranges::set_intersection (Rng1 &&rng1, Rng2 &&rng2, O out, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I1 , typename S1 , typename I2 , typename S2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>
set_symmetric_difference_result< I1, I2, O > | ranges::set_symmetric_difference (I1 begin1, S1 end1, I2 begin2, S2 end2, O out, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| function template `set_symmetric_difference` More...
template<typename Rng1 , typename Rng2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>
set_symmetric_difference_result< borrowed_iterator_t< Rng1 >, borrowed_iterator_t< Rng2 >, O > | ranges::set_symmetric_difference (Rng1 &&rng1, Rng2 &&rng2, O out, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I1 , typename S1 , typename I2 , typename S2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>
set_union_result< I1, I2, O > | ranges::set_union (I1 begin1, S1 end1, I2 begin2, S2 end2, O out, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| function template `set_union` More...
template<typename Rng1 , typename Rng2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>
set_union_result< borrowed_iterator_t< Rng1 >, borrowed_iterator_t< Rng2 >, O > | ranges::set_union (Rng1 &&rng1, Rng2 &&rng2, O out, C pred=C{}, P1 proj1=P1{}, P2 proj2=P2{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename Gen = detail::default_random_engine &>
I | ranges::shuffle (I const first, S const last, Gen &&gen=detail::get_random_engine())
| function template `shuffle` More...
template<typename Rng , typename Gen = detail::default_random_engine &>
borrowed_iterator_t< Rng > | ranges::shuffle (Rng &&rng, Gen &&rand=detail::get_random_engine())
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::sort (I first, S end_, C pred=C{}, P proj=P{})
| function template `sort` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::sort (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::sort_heap (I first, S last, C pred=C{}, P proj=P{})
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::sort_heap (Rng &&rng, C pred=C{}, P proj=P{})
template<typename I , typename S , typename C , typename P = identity>
I | ranges::stable_partition (I first, S last, C pred, P proj=P{})
| function template `stable_partition` More...
template<typename Rng , typename C , typename P = identity>
borrowed_iterator_t< Rng > | ranges::stable_partition (Rng &&rng, C pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = less, typename P = identity>
I | ranges::stable_sort (I first, S end_, C pred=C{}, P proj=P{})
| function template `stable_sort` More...
template<typename Rng , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::stable_sort (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I1 , typename S1 , typename I2 , typename S2 , typename Comp = equal_to, typename Proj1 = identity, typename Proj2 = identity>
constexpr bool | ranges::starts_with (I1 first1, S1 last1, I2 first2, S2 last2, Comp comp={}, Proj1 proj1={}, Proj2 proj2={})
| function template `starts_with` More...
template<typename R1 , typename R2 , typename Comp = equal_to, typename Proj1 = identity, typename Proj2 = identity>
constexpr bool | ranges::starts_with (R1 &&r1, R2 &&r2, Comp comp={}, Proj1 proj1={}, Proj2 proj2={})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I1 , typename S1 , typename I2 >
swap_ranges_result< I1, I2 > | ranges::swap_ranges (I1 begin1, S1 end1, I2 begin2)
| function template `swap_ranges` More...
template<typename I1 , typename S1 , typename I2 , typename S2 >
swap_ranges_result< I1, I2 > | ranges::swap_ranges (I1 begin1, S1 end1, I2 begin2, S2 end2)
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng1 , typename I2_ >
swap_ranges_result< iterator_t< Rng1 >, uncvref_t< I2_ > > | ranges::swap_ranges (Rng1 &&rng1, I2_ &&begin2)
template<typename Rng1 , typename Rng2 >
swap_ranges_result< borrowed_iterator_t< Rng1 >, borrowed_iterator_t< Rng2 > > | ranges::swap_ranges (Rng1 &&rng1, Rng2 &&rng2)
template<typename I , typename S , typename O , typename F , typename P = identity>
unary_transform_result< I, O > | ranges::transform (I first, S last, O out, F fun, P proj=P{})
| function template `transform` More...
template<typename I0 , typename S0 , typename I1 , typename O , typename F , typename P0 = identity, typename P1 = identity>
binary_transform_result< I0, I1, O > | ranges::transform (I0 begin0, S0 end0, I1 begin1, O out, F fun, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I0 , typename S0 , typename I1 , typename S1 , typename O , typename F , typename P0 = identity, typename P1 = identity>
binary_transform_result< I0, I1, O > | ranges::transform (I0 begin0, S0 end0, I1 begin1, S1 end1, O out, F fun, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng , typename O , typename F , typename P = identity>
unary_transform_result< borrowed_iterator_t< Rng >, O > | ranges::transform (Rng &&rng, O out, F fun, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng0 , typename I1Ref , typename O , typename F , typename P0 = identity, typename P1 = identity>
binary_transform_result< borrowed_iterator_t< Rng0 >, uncvref_t< I1Ref >, O > | ranges::transform (Rng0 &&rng0, I1Ref &&begin1, O out, F fun, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename Rng0 , typename Rng1 , typename O , typename F , typename P0 = identity, typename P1 = identity>
binary_transform_result< borrowed_iterator_t< Rng0 >, borrowed_iterator_t< Rng1 >, O > | ranges::transform (Rng0 &&rng0, Rng1 &&rng1, O out, F fun, P0 proj0=P0{}, P1 proj1=P1{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename C = equal_to, typename P = identity>
I | ranges::unique (I first, S last, C pred=C{}, P proj=P{})
| template function `unique` More...
template<typename Rng , typename C = equal_to, typename P = identity>
borrowed_iterator_t< Rng > | ranges::unique (Rng &&rng, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename O , typename C = equal_to, typename P = identity>
unique_copy_result< I, O > | ranges::unique_copy (I first, S last, O out, C pred=C{}, P proj=P{})
| template function unique_copy More...
template<typename Rng , typename O , typename C = equal_to, typename P = identity>
unique_copy_result< borrowed_iterator_t< Rng >, O > | ranges::unique_copy (Rng &&rng, O out, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename C , typename P = identity>
I | ranges::unstable_remove_if (I first, I last, C pred, P proj={})
| unstable_remove have O(1) complexity for each element remove, unlike remove O(n) [for worst case]. Each erased element overwritten (moved in) with last one. unstable_remove_if does not preserve relative element order. More...
template<typename Rng , typename C , typename P = identity>
borrowed_iterator_t< Rng > | ranges::unstable_remove_if (Rng &&rng, C pred, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
template<typename I , typename S , typename V , typename C = less, typename P = identity>
I | ranges::upper_bound (I first, S last, V const &val, C pred=C{}, P proj=P{})
| function template `upper_bound` More...
template<typename Rng , typename V , typename C = less, typename P = identity>
borrowed_iterator_t< Rng > | ranges::upper_bound (Rng &&rng, V const &val, C pred=C{}, P proj=P{})
| This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...

## Function Documentation

## ◆ adjacent_find() [1/2]

template<typename I , typename S , typename C = equal_to, typename P = identity>

I ranges::adjacent_find | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/adjacent_find.hpp>`

function template `adjacent_find`

range-based version of the `adjacent_find` std algorithm

Precondition
  `Rng` is a model of the `range` concept
  `C` is a model of the `BinaryPredicate` concept
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_relation<C, projected<I, P>>`

## ◆ adjacent_find() [2/2]

template<typename Rng , typename C = equal_to, typename P = identity>

borrowed_iterator_t<Rng> ranges::adjacent_find | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/adjacent_find.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_relation<C, projected<iterator_t<Rng>, P>>`

## ◆ adjacent_remove_if() [1/2]

template<typename I , typename S , typename Pred , typename Proj = identity>

I ranges::adjacent_remove_if | ( | I | first,
|  | S | last,
|  | Pred | pred = `{}`,
|  | Proj | proj = `{}`
| ) |  |

`#include <range/v3/algorithm/adjacent_remove_if.hpp>`

function `adjacent_remove_if`

range-based version of the `adjacent_remove_if` algorithm

Precondition
  `Rng` is a model of the `forward_range` concept.
  `Pred` is a model of the `BinaryPredicate` concept.
  requires `permutable<I> && sentinel_for<S, I> && indirect_relation<Pred, projected<I, Proj>>`

References ranges::adjacent_remove_if().

## ◆ adjacent_remove_if() [2/2]

template<typename Rng , typename Pred , typename Proj = identity>

borrowed_iterator_t<Rng> ranges::adjacent_remove_if | ( | Rng && | rng,
|  | Pred | pred,
|  | Proj | proj = `{}`
| ) |  |

`#include <range/v3/algorithm/adjacent_remove_if.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_relation<Pred, projected<iterator_t<Rng>, Proj>> && permutable<iterator_t<Rng>>`

Referenced by ranges::adjacent_remove_if().

## ◆ all_of() [1/2]

template<typename I , typename S , typename F , typename P = identity>

bool ranges::all_of | ( | I | first,
|  | S | last,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/all_of.hpp>`

function template `all_of`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_unary_predicate<F, projected<I, P>>`

## ◆ all_of() [2/2]

template<typename Rng , typename F , typename P = identity>

bool ranges::all_of | ( | Rng && | rng,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/all_of.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_unary_predicate<F, projected<iterator_t<Rng>, P>>`

## ◆ any_of() [1/2]

template<typename I , typename S , typename F , typename P = identity>

bool ranges::any_of | ( | I | first,
|  | S | last,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/any_of.hpp>`

function template `any_of`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_unary_predicate<F, projected<I, P>>`

## ◆ any_of() [2/2]

template<typename Rng , typename F , typename P = identity>

bool ranges::any_of | ( | Rng && | rng,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/any_of.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_unary_predicate<F, projected<iterator_t<Rng>, P>>`

## ◆ binary_search() [1/2]

template<typename I , typename S , typename V , typename C = less, typename P = identity>

bool ranges::binary_search | ( | I | first,
|  | S | last,
|  | V const & | val,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/binary_search.hpp>`

function template `binary_search`

range-based version of the `binary_search` std algorithm

Precondition
  `Rng` is a model of the `range` concept
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<C, V const *, projected<I, P>>`

## ◆ binary_search() [2/2]

template<typename Rng , typename V , typename C = less, typename P = identity>

bool ranges::binary_search | ( | Rng && | rng,
|  | V const & | val,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/binary_search.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_strict_weak_order<C, V const *, projected<iterator_t<Rng>, P>>`

## ◆ contains() [1/2]

template<typename I , typename S , typename T , typename P = identity>

constexpr bool ranges::contains | ( | I | first,
|  | S | last,
|  | const T & | val,
|  | P | proj = `{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/contains.hpp>`

function template `contains`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_relation<equal_to, projected<I, P>, const T *>`

## ◆ contains() [2/2]

template<typename Rng , typename T , typename P = identity>

constexpr bool ranges::contains | ( | Rng && | rng,
|  | const T & | val,
|  | P | proj = `{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/contains.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_relation<equal_to, projected<iterator_t<Rng>, P>, const T *>`

## ◆ copy() [1/2]

template<typename I , typename S , typename O >

constexpr copy_result<I, O> ranges::copy | ( | I | first,
|  | S | last,
|  | O | out
| ) |  |
| constexpr

`#include <range/v3/algorithm/copy.hpp>`

function template `copy`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && weakly_incrementable<O> && indirectly_copyable<I, O>`

## ◆ copy() [2/2]

template<typename Rng , typename O >

constexpr copy_result<borrowed_iterator_t<Rng>, O> ranges::copy | ( | Rng && | rng,
|  | O | out
| ) |  |
| constexpr

`#include <range/v3/algorithm/copy.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && weakly_incrementable<O> && indirectly_copyable<iterator_t<Rng>, O>`

## ◆ copy_backward() [1/2]

template<typename I , typename S , typename O >

copy_backward_result<I, O> ranges::copy_backward | ( | I | first,
|  | S | end_,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/copy_backward.hpp>`

function template `copy_backward`

Precondition
  requires `bidirectional_iterator<I> && sentinel_for<S, I> && bidirectional_iterator<O> && indirectly_copyable<I, O>`

## ◆ copy_backward() [2/2]

template<typename Rng , typename O >

copy_backward_result<borrowed_iterator_t<Rng>, O> ranges::copy_backward | ( | Rng && | rng,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/copy_backward.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `bidirectional_range<Rng> && bidirectional_iterator<O> && indirectly_copyable<iterator_t<Rng>, O>`

## ◆ copy_if() [1/2]

template<typename I , typename S , typename O , typename F , typename P = identity>

copy_if_result<I, O> ranges::copy_if | ( | I | first,
|  | S | last,
|  | O | out,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/copy_if.hpp>`

function template `copy_if`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && weakly_incrementable<O> && indirect_unary_predicate<F, projected<I, P>> && indirectly_copyable<I, O>`

## ◆ copy_if() [2/2]

template<typename Rng , typename O , typename F , typename P = identity>

copy_if_result<borrowed_iterator_t<Rng>, O> ranges::copy_if | ( | Rng && | rng,
|  | O | out,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/copy_if.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && weakly_incrementable<O> && indirect_unary_predicate<F, projected<iterator_t<Rng>, P>> && indirectly_copyable<iterator_t<Rng>, O>`

## ◆ copy_n()

template<typename I , typename O , typename P = identity>

copy_n_result<I, O> ranges::copy_n | ( | I | first,
|  | iter_difference_t< I > | n,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/copy_n.hpp>`

function template `copy_n`

Precondition
  requires `input_iterator<I> && weakly_incrementable<O> && indirectly_copyable<I, O>`

## ◆ count() [1/2]

template<typename I , typename S , typename V , typename P = identity>

iter_difference_t<I> ranges::count | ( | I | first,
|  | S | last,
|  | V const & | val,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/count.hpp>`

function template `count`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_relation<equal_to, projected<I, P>, V const *>`

## ◆ count() [2/2]

template<typename Rng , typename V , typename P = identity>

iter_difference_t<iterator_t<Rng> > ranges::count | ( | Rng && | rng,
|  | V const & | val,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/count.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_relation<equal_to, projected<iterator_t<Rng>, P>, V const *>`

## ◆ count_if() [1/2]

template<typename I , typename S , typename R , typename P = identity>

iter_difference_t<I> ranges::count_if | ( | I | first,
|  | S | last,
|  | R | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/count_if.hpp>`

function template `count_if`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_unary_predicate<R, projected<I, P>>`

## ◆ count_if() [2/2]

template<typename Rng , typename R , typename P = identity>

iter_difference_t<iterator_t<Rng> > ranges::count_if | ( | Rng && | rng,
|  | R | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/count_if.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_unary_predicate<R, projected<iterator_t<Rng>, P>>`

## ◆ ends_with() [1/2]

template<typename I0 , typename S0 , typename I1 , typename S1 , typename C = equal_to, typename P0 = identity, typename P1 = identity>

constexpr bool ranges::ends_with | ( | I0 | begin0,
|  | S0 | end0,
|  | I1 | begin1,
|  | S1 | end1,
|  | C | pred = `C{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/ends_with.hpp>`

function template `ends_with`

Precondition
  requires `((forward_iterator<I0> && sentinel_for<S0, I0>) || (input_iterator<I0> && sized_sentinel_for<S0, I0>)) && ((forward_iterator<I1> && sentinel_for<S1, I1>) || (input_iterator<I1> && sized_sentinel_for<S1, I1>)) && indirectly_comparable<I0, I1, C, P0, P1>`

## ◆ ends_with() [2/2]

template<typename Rng0 , typename Rng1 , typename C = equal_to, typename P0 = identity, typename P1 = identity>

constexpr bool ranges::ends_with | ( | Rng0 && | rng0,
|  | Rng1 && | rng1,
|  | C | pred = `C{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/ends_with.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `(forward_range<Rng0> || (input_range<Rng0> && sized_range<Rng0>)) && (forward_range<Rng1> || (input_range<Rng1> && sized_range<Rng1>)) && indirectly_comparable<iterator_t<Rng0>, iterator_t<Rng1>, C, P0, P1>`

References ranges::distance, ranges::equal(), ranges::aux::move, and ranges::next.

## ◆ equal() [1/4]

template<typename I0 , typename S0 , typename I1 , typename C = equal_to, typename P0 = identity, typename P1 = identity>

constexpr bool ranges::equal | ( | I0 | begin0,
|  | S0 | end0,
|  | I1 | begin1,
|  | C | pred = `C{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/equal.hpp>`

function template `equal`

Precondition
  requires `input_iterator<I0> && sentinel_for<S0, I0> && input_iterator<I1> && indirectly_comparable<I0, I1, C, P0, P1>`

Referenced by ranges::ends_with().

## ◆ equal() [2/4]

template<typename I0 , typename S0 , typename I1 , typename S1 , typename C = equal_to, typename P0 = identity, typename P1 = identity>

constexpr bool ranges::equal | ( | I0 | begin0,
|  | S0 | end0,
|  | I1 | begin1,
|  | S1 | end1,
|  | C | pred = `C{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/equal.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_iterator<I0> && sentinel_for<S0, I0> && input_iterator<I1> && sentinel_for<S1, I1> && indirectly_comparable<I0, I1, C, P0, P1>`

## ◆ equal() [3/4]

template<typename Rng0 , typename I1Ref , typename C = equal_to, typename P0 = identity, typename P1 = identity>

constexpr bool ranges::equal | ( | Rng0 && | rng0,
|  | I1Ref && | begin1,
|  | C | pred = `C{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/equal.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng0> && input_iterator<uncvref_t<I1Ref>> && indirectly_comparable<iterator_t<Rng0>, uncvref_t<I1Ref>, C, P0, P1>`

## ◆ equal() [4/4]

template<typename Rng0 , typename Rng1 , typename C = equal_to, typename P0 = identity, typename P1 = identity>

constexpr bool ranges::equal | ( | Rng0 && | rng0,
|  | Rng1 && | rng1,
|  | C | pred = `C{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/equal.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng0> && input_range<Rng1> && indirectly_comparable<iterator_t<Rng0>, iterator_t<Rng1>, C, P0, P1>`

## ◆ equal_range() [1/2]

template<typename I , typename S , typename V , typename C = less, typename P = identity>

subrange<I> ranges::equal_range | ( | I | first,
|  | S | last,
|  | V const & | val,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/equal_range.hpp>`

function template `equal_range`

Precondition
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<C, V const *, projected<I, P>>`

## ◆ equal_range() [2/2]

template<typename Rng , typename V , typename C = less, typename P = identity>

borrowed_subrange_t<Rng> ranges::equal_range | ( | Rng && | rng,
|  | V const & | val,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/equal_range.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_strict_weak_order<C, V const *, projected<iterator_t<Rng>, P>>`

## ◆ fill() [1/2]

template<typename O , typename S , typename V >

O ranges::fill | ( | O | first,
|  | S | last,
|  | V const & | val
| ) |  |

`#include <range/v3/algorithm/fill.hpp>`

function template `fill`

Precondition
  requires `output_iterator<O, V const &> && sentinel_for<S, O>`

## ◆ fill() [2/2]

template<typename Rng , typename V >

borrowed_iterator_t<Rng> ranges::fill | ( | Rng && | rng,
|  | V const & | val
| ) |  |

`#include <range/v3/algorithm/fill.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `output_range<Rng, V const &>`

## ◆ fill_n()

template<typename O , typename V >

O ranges::fill_n | ( | O | first,
|  | iter_difference_t< O > | n,
|  | V const & | val
| ) |  |

`#include <range/v3/algorithm/fill_n.hpp>`

function template `equal`

Precondition
  requires `output_iterator<O, V const &>`

## ◆ find() [1/2]

template<typename I , typename S , typename V , typename P = identity>

constexpr I ranges::find | ( | I | first,
|  | S | last,
|  | V const & | val,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/find.hpp>`

template function `find`

range-based version of the `find` std algorithm

Precondition
  `Rng` is a model of the `range` concept
  `I` is a model of the `input_iterator` concept
  `S` is a model of the `sentinel_for<I>` concept
  `P` is a model of the `invocable<iter_common_reference_t<I>>` concept
  The ResultType of `P` is equality_comparable with V
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_relation<equal_to, projected<I, P>, V const *>`

## ◆ find() [2/2]

template<typename Rng , typename V , typename P = identity>

constexpr borrowed_iterator_t<Rng> ranges::find | ( | Rng && | rng,
|  | V const & | val,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/find.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_relation<equal_to, projected<iterator_t<Rng>, P>, V const *>`

## ◆ find_end() [1/2]

template<typename I1 , typename S1 , typename I2 , typename S2 , typename R = equal_to, typename P = identity>

subrange<I1> ranges::find_end | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | S2 | end2,
|  | R | pred = `R{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/find_end.hpp>`

function template `find_end`

Precondition
  requires `forward_iterator<I1> && sentinel_for<S1, I1> && forward_iterator<I2> && sentinel_for<S2, I2> && indirect_relation<R, projected<I1, P>, I2>`

## ◆ find_end() [2/2]

template<typename Rng1 , typename Rng2 , typename R = equal_to, typename P = identity>

borrowed_subrange_t<Rng1> ranges::find_end | ( | Rng1 && | rng1,
|  | Rng2 && | rng2,
|  | R | pred = `R{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/find_end.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng1> && forward_range<Rng2> && indirect_relation<R, projected<iterator_t<Rng1>, P>, iterator_t<Rng2>>`

## ◆ find_first_of() [1/2]

template<typename I0 , typename S0 , typename I1 , typename S1 , typename R = equal_to, typename P0 = identity, typename P1 = identity>

constexpr I0 ranges::find_first_of | ( | I0 | begin0,
|  | S0 | end0,
|  | I1 | begin1,
|  | S1 | end1,
|  | R | pred = `R{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/find_first_of.hpp>`

function template `find_first_of`

Precondition
  requires `input_iterator<I0> && sentinel_for<S0, I0> && forward_iterator<I1> && sentinel_for<S1, I1> && indirect_relation<R, projected<I0, P0>, projected<I1, P1>>`

## ◆ find_first_of() [2/2]

template<typename Rng0 , typename Rng1 , typename R = equal_to, typename P0 = identity, typename P1 = identity>

constexpr borrowed_iterator_t<Rng0> ranges::find_first_of | ( | Rng0 && | rng0,
|  | Rng1 && | rng1,
|  | R | pred = `R{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/find_first_of.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng0> && forward_range<Rng1> && indirect_relation<R, projected<iterator_t<Rng0>, P0>, projected<iterator_t<Rng1>, P1>>`

## ◆ find_if() [1/2]

template<typename I , typename S , typename F , typename P = identity>

I ranges::find_if | ( | I | first,
|  | S | last,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/find_if.hpp>`

template function `find`

range-based version of the `find` std algorithm

Precondition
  `Rng` is a model of the `range` concept
  `I` is a model of the `input_iterator` concept
  `S` is a model of the `sentinel_for<I>` concept
  `P` is a model of the `invocable<V>` concept, where `V` is the value type of I.
  `F` models `predicate<X>`, where `X` is the result type of `invocable<P, V>`
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_unary_predicate<F, projected<I, P>>`

## ◆ find_if() [2/2]

template<typename Rng , typename F , typename P = identity>

borrowed_iterator_t<Rng> ranges::find_if | ( | Rng && | rng,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/find_if.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_unary_predicate<F, projected<iterator_t<Rng>, P>>`

## ◆ find_if_not() [1/2]

template<typename I , typename S , typename F , typename P = identity>

I ranges::find_if_not | ( | I | first,
|  | S | last,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/find_if_not.hpp>`

template function `find_if_not`

range-based version of the `find_if_not` std algorithm

Precondition
  `Rng` is a model of the `range` concept
  `I` is a model of the `input_iterator` concept
  `S` is a model of the `sentinel_for<I>` concept
  `P` is a model of the `invocable<V>` concept, where `V` is the value type of I.
  `F` models `predicate<X>`, where `X` is the result type of `invocable<P, V>`
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_unary_predicate<F, projected<I, P>>`

## ◆ find_if_not() [2/2]

template<typename Rng , typename F , typename P = identity>

borrowed_iterator_t<Rng> ranges::find_if_not | ( | Rng && | rng,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/find_if_not.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_unary_predicate<F, projected<iterator_t<Rng>, P>>`

## ◆ for_each() [1/2]

template<typename I , typename S , typename F , typename P = identity>

for_each_result<I, F> ranges::for_each | ( | I | first,
|  | S | last,
|  | F | fun,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/for_each.hpp>`

function template `for_each`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && indirectly_unary_invocable<F, projected<I, P>>`

## ◆ for_each() [2/2]

template<typename Rng , typename F , typename P = identity>

for_each_result<borrowed_iterator_t<Rng>, F> ranges::for_each | ( | Rng && | rng,
|  | F | fun,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/for_each.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirectly_unary_invocable<F, projected<iterator_t<Rng>, P>>`

## ◆ for_each_n() [1/2]

template<typename I , typename F , typename P = identity>

I ranges::for_each_n | ( | I | first,
|  | iter_difference_t< I > | n,
|  | F | fun,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/for_each_n.hpp>`

function template `for_each_n`

Precondition
  requires `input_iterator<I> && indirectly_unary_invocable<F, projected<I, P>>`

## ◆ for_each_n() [2/2]

template<typename Rng , typename F , typename P = identity>

borrowed_iterator_t<Rng> ranges::for_each_n | ( | Rng && | rng,
|  | range_difference_t< Rng > | n,
|  | F | fun,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/for_each_n.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirectly_unary_invocable<F, projected<iterator_t<Rng>, P>>`

## ◆ generate() [1/2]

template<typename O , typename S , typename F >

generate_result<O, F> ranges::generate | ( | O | first,
|  | S | last,
|  | F | fun
| ) |  |

`#include <range/v3/algorithm/generate.hpp>`

function template `generate_n`

Precondition
  requires `invocable<F &> && output_iterator<O, invoke_result_t<F &>> && sentinel_for<S, O>`

## ◆ generate() [2/2]

template<typename Rng , typename F >

generate_result<borrowed_iterator_t<Rng>, F> ranges::generate | ( | Rng && | rng,
|  | F | fun
| ) |  |

`#include <range/v3/algorithm/generate.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `invocable<F &> && output_range<Rng, invoke_result_t<F &>>`

References ranges::aux::move.

## ◆ generate_n()

template<typename O , typename F >

generate_n_result<O, F> ranges::generate_n | ( | O | first,
|  | iter_difference_t< O > | n,
|  | F | fun
| ) |  |

`#include <range/v3/algorithm/generate_n.hpp>`

function template `generate_n`

Precondition
  requires `invocable<F &> && output_iterator<O, invoke_result_t<F &>>`

## ◆ includes() [1/2]

template<typename I1 , typename S1 , typename I2 , typename S2 , typename C = less, typename P1 = identity, typename P2 = identity>

bool ranges::includes | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | S2 | end2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/set_algorithm.hpp>`

function template `includes`

Precondition
  requires `input_iterator<I1> && sentinel_for<S1, I1> && input_iterator<I2> && sentinel_for<S2, I2> && indirect_strict_weak_order<C, projected<I1, P1>, projected<I2, P2>>`

References ranges::includes().

## ◆ includes() [2/2]

template<typename Rng1 , typename Rng2 , typename C = less, typename P1 = identity, typename P2 = identity>

bool ranges::includes | ( | Rng1 && | rng1,
|  | Rng2 && | rng2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/set_algorithm.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng1> && input_range<Rng2> && indirect_strict_weak_order<C, projected<iterator_t<Rng1>, P1>, projected<iterator_t<Rng2>, P2>>`

Referenced by ranges::includes().

## ◆ inplace_merge() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::inplace_merge | ( | I | first,
|  | I | middle,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/inplace_merge.hpp>`

function template `inplace_merge`

Precondition
  requires `bidirectional_iterator<I> && sortable<I, C, P>`

## ◆ inplace_merge() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::inplace_merge | ( | Rng && | rng,
|  | iterator_t< Rng > | middle,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/inplace_merge.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `bidirectional_range<Rng> && sortable<iterator_t<Rng>, C, P>`

## ◆ is_heap() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

bool ranges::is_heap | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

function template `is_heap`

Precondition
  requires `random_access_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<C, projected<I, P>>`

## ◆ is_heap() [2/2]

template<typename Rng , typename C = less, typename P = identity>

bool ranges::is_heap | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `random_access_range<Rng> && indirect_strict_weak_order<C, projected<iterator_t<Rng>, P>>`

## ◆ is_heap_until() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::is_heap_until | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

function template `is_heap_until`

Precondition
  requires `random_access_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<C, projected<I, P>>`

## ◆ is_heap_until() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::is_heap_until | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `random_access_range<Rng> && indirect_strict_weak_order<C, projected<iterator_t<Rng>, P>>`

## ◆ is_partitioned() [1/2]

template<typename I , typename S , typename C , typename P = identity>

bool ranges::is_partitioned | ( | I | first,
|  | S | last,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/is_partitioned.hpp>`

function template `is_partitioned`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_unary_predicate<C, projected<I, P>>`

## ◆ is_partitioned() [2/2]

template<typename Rng , typename C , typename P = identity>

bool ranges::is_partitioned | ( | Rng && | rng,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/is_partitioned.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_unary_predicate<C, projected<iterator_t<Rng>, P>>`

## ◆ is_permutation() [1/4]

template<typename I1 , typename S1 , typename I2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>

bool ranges::is_permutation | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/permutation.hpp>`

function template `is_permutation`

Precondition
  requires `forward_iterator<I1> && sentinel_for<S1, I1> && forward_iterator<I2> && indirectly_comparable<I1, I2, C, P1, P2>`

## ◆ is_permutation() [2/4]

template<typename I1 , typename S1 , typename I2 , typename S2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>

bool ranges::is_permutation | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | S2 | end2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/permutation.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_iterator<I1> && sentinel_for<S1, I1> && forward_iterator<I2> && sentinel_for<S2, I2> && indirectly_comparable<I1, I2, C, P1, P2>`

References ranges::next.

## ◆ is_permutation() [3/4]

template<typename Rng1 , typename I2Ref , typename C = equal_to, typename P1 = identity, typename P2 = identity>

bool ranges::is_permutation | ( | Rng1 && | rng1,
|  | I2Ref && | begin2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/permutation.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng1> && forward_iterator<uncvref_t<I2Ref>> && indirectly_comparable<iterator_t<Rng1>, uncvref_t<I2Ref>, C, P1, P2>`

## ◆ is_permutation() [4/4]

template<typename Rng1 , typename Rng2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>

bool ranges::is_permutation | ( | Rng1 && | rng1,
|  | Rng2 && | rng2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/permutation.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng1> && forward_range<Rng2> && indirectly_comparable<iterator_t<Rng1>, iterator_t<Rng2>, C, P1, P2>`

## ◆ is_sorted() [1/2]

template<typename I , typename S , typename R = less, typename P = identity>

bool ranges::is_sorted | ( | I | first,
|  | S | last,
|  | R | rel = `R{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/is_sorted.hpp>`

template function `is_sorted`

range-based version of the `is_sorted` std algorithm

Works on forward_ranges

Precondition
  `Rng` is a model of the `forward_range` concept
  `I` is a model of the `forward_iterator` concept
  `S` and `I` model the `sentinel_for<S, I>` concept
  `R` and `projected<I, P>` model the `indirect_strict_weak_order<R, projected<I, P>>` concept
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<R, projected<I, P>>`

## ◆ is_sorted() [2/2]

template<typename Rng , typename R = less, typename P = identity>

bool ranges::is_sorted | ( | Rng && | rng,
|  | R | rel = `R{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/is_sorted.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_strict_weak_order<R, projected<iterator_t<Rng>, P>>`

## ◆ is_sorted_until() [1/2]

template<typename I , typename S , typename R = less, typename P = identity>

I ranges::is_sorted_until | ( | I | first,
|  | S | last,
|  | R | pred = `R{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/is_sorted_until.hpp>`

template function `is_sorted_until`

range-based version of the `is_sorted_until` std algorithm

Works on forward_ranges

Precondition
  `Rng` is a model of the `forward_range` concept
  `I` is a model of the `forward_iterator` concept
  `S` and `I` model the `sentinel_for<S, I>` concept
  `R` and `projected<I, P>` model the `indirect_strict_weak_order<R, projected<I, P>>` concept
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<R, projected<I, P>>`

## ◆ is_sorted_until() [2/2]

template<typename Rng , typename R = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::is_sorted_until | ( | Rng && | rng,
|  | R | pred = `R{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/is_sorted_until.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_strict_weak_order<R, projected<iterator_t<Rng>, P>>`

## ◆ lexicographical_compare() [1/2]

template<typename I0 , typename S0 , typename I1 , typename S1 , typename C = less, typename P0 = identity, typename P1 = identity>

bool ranges::lexicographical_compare | ( | I0 | begin0,
|  | S0 | end0,
|  | I1 | begin1,
|  | S1 | end1,
|  | C | pred = `C{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |

`#include <range/v3/algorithm/lexicographical_compare.hpp>`

function template `lexicographical_compare`

Precondition
  requires `input_iterator<I0> && sentinel_for<S0, I0> && input_iterator<I1> && sentinel_for<S1, I1> && indirect_strict_weak_order<C, projected<I0, P0>, projected<I1, P1>>`

References ranges::lexicographical_compare().

## ◆ lexicographical_compare() [2/2]

template<typename Rng0 , typename Rng1 , typename C = less, typename P0 = identity, typename P1 = identity>

bool ranges::lexicographical_compare | ( | Rng0 && | rng0,
|  | Rng1 && | rng1,
|  | C | pred = `C{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |

`#include <range/v3/algorithm/lexicographical_compare.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng0> && input_range<Rng1> && indirect_strict_weak_order<C, projected<iterator_t<Rng0>, P0>, projected<iterator_t<Rng1>, P1>>`

Referenced by ranges::lexicographical_compare().

## ◆ lower_bound() [1/2]

template<typename I , typename S , typename V , typename C = less, typename P = identity>

I ranges::lower_bound | ( | I | first,
|  | S | last,
|  | V const & | val,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/lower_bound.hpp>`

function template `lower_bound`

Precondition
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<C, V const *, projected<I, P>>`

## ◆ lower_bound() [2/2]

template<typename Rng , typename V , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::lower_bound | ( | Rng && | rng,
|  | V const & | val,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/lower_bound.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_strict_weak_order<C, V const *, projected<iterator_t<Rng>, P>>`

References ranges::aux::move, and ranges::partition_point().

## ◆ make_heap() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::make_heap | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

function template `make_heap`

Precondition
  requires `random_access_iterator<I> && sentinel_for<S, I> && sortable<I, C, P>`

Referenced by ranges::partial_sort_copy().

## ◆ make_heap() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::make_heap | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `random_access_range<Rng> && sortable<iterator_t<Rng>, C, P>`

## ◆ max() [1/3]

template<typename Rng , typename C = less, typename P = identity>

constexpr range_value_t<Rng> ranges::max | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/max.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_strict_weak_order<C, projected<iterator_t<Rng>, P>> && indirectly_copyable_storable<iterator_t<Rng>, range_value_t<Rng> *>`

## ◆ max() [2/3]

template<typename T , typename C = less, typename P = identity>

constexpr T ranges::max | ( | std::initializer_list< T > const && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/max.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `copyable<T> && indirect_strict_weak_order<C, projected<T const *, P>>`

## ◆ max() [3/3]

template<typename T , typename C = less, typename P = identity>

constexpr T const& ranges::max | ( | T const & | a,
|  | T const & | b,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/max.hpp>`

function template `max`

Precondition
  requires `indirect_strict_weak_order<C, projected<T const *, P>>`

## ◆ max_element() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::max_element | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/max_element.hpp>`

function template `max_element`

Precondition
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<C, projected<I, P>>`

## ◆ max_element() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::max_element | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/max_element.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_strict_weak_order<C, projected<iterator_t<Rng>, P>>`

## ◆ merge() [1/2]

template<typename I0 , typename S0 , typename I1 , typename S1 , typename O , typename C = less, typename P0 = identity, typename P1 = identity>

merge_result<I0, I1, O> ranges::merge | ( | I0 | begin0,
|  | S0 | end0,
|  | I1 | begin1,
|  | S1 | end1,
|  | O | out,
|  | C | pred = `C{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |

`#include <range/v3/algorithm/merge.hpp>`

function template `merge`

Precondition
  requires `sentinel_for<S0, I0> && sentinel_for<S1, I1> && mergeable<I0, I1, O, C, P0, P1>`

References ranges::merge().

## ◆ merge() [2/2]

template<typename Rng0 , typename Rng1 , typename O , typename C = less, typename P0 = identity, typename P1 = identity>

merge_result<borrowed_iterator_t<Rng0>, borrowed_iterator_t<Rng1>, O> ranges::merge | ( | Rng0 && | rng0,
|  | Rng1 && | rng1,
|  | O | out,
|  | C | pred = `C{}`,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |

`#include <range/v3/algorithm/merge.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `range<Rng0> && range<Rng1> && mergeable<iterator_t<Rng0>, iterator_t<Rng1>, O, C, P0, P1>`

Referenced by ranges::merge().

## ◆ min() [1/3]

template<typename Rng , typename C = less, typename P = identity>

constexpr range_value_t<Rng> ranges::min | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/min.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_strict_weak_order<C, projected<iterator_t<Rng>, P>> && indirectly_copyable_storable<iterator_t<Rng>, range_value_t<Rng> *>`

## ◆ min() [2/3]

template<typename T , typename C = less, typename P = identity>

constexpr T ranges::min | ( | std::initializer_list< T > const && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/min.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `copyable<T> && indirect_strict_weak_order<C, projected<T const *, P>>`

## ◆ min() [3/3]

template<typename T , typename C = less, typename P = identity>

constexpr T const& ranges::min | ( | T const & | a,
|  | T const & | b,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/min.hpp>`

function template `min`

Precondition
  requires `indirect_strict_weak_order<C, projected<T const *, P>>`

## ◆ min_element() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::min_element | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/min_element.hpp>`

function template `min_element`

Precondition
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<C, projected<I, P>>`

## ◆ min_element() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::min_element | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/min_element.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_strict_weak_order<C, projected<iterator_t<Rng>, P>>`

## ◆ minmax() [1/3]

template<typename Rng , typename C = less, typename P = identity>

constexpr minmax_result<range_value_t<Rng> > ranges::minmax | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/minmax.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_strict_weak_order<C, projected<iterator_t<Rng>, P>> && indirectly_copyable_storable<iterator_t<Rng>, range_value_t<Rng> *>`

## ◆ minmax() [2/3]

template<typename T , typename C = less, typename P = identity>

constexpr minmax_result<T> ranges::minmax | ( | std::initializer_list< T > const && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/minmax.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `copyable<T> && indirect_strict_weak_order<C, projected<T const *, P>>`

## ◆ minmax() [3/3]

template<typename T , typename C = less, typename P = identity>

constexpr minmax_result<T const &> ranges::minmax | ( | T const & | a,
|  | T const & | b,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/minmax.hpp>`

function template `minmax`

Precondition
  requires `indirect_strict_weak_order<C, projected<T const *, P>>`

## ◆ minmax_element() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

minmax_element_result<I> ranges::minmax_element | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/minmax_element.hpp>`

function template `minmax_element`

Precondition
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<C, projected<I, P>>`

## ◆ minmax_element() [2/2]

template<typename Rng , typename C = less, typename P = identity>

minmax_element_result<borrowed_iterator_t<Rng> > ranges::minmax_element | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/minmax_element.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_strict_weak_order<C, projected<iterator_t<Rng>, P>>`

## ◆ mismatch() [1/3]

template<typename I1 , typename S1 , typename I2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>

mismatch_result<I1, I2> ranges::mismatch | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/mismatch.hpp>`

function template `mismatch`

Precondition
  requires `input_iterator<I1> && sentinel_for<S1, I1> && input_iterator<I2> && indirect_relation<C, projected<I1, P1>, projected<I2, P2>>`

## ◆ mismatch() [2/3]

template<typename I1 , typename S1 , typename I2 , typename S2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>

mismatch_result<I1, I2> ranges::mismatch | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | S2 | end2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/mismatch.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_iterator<I1> && sentinel_for<S1, I1> && input_iterator<I2> && sentinel_for<S2, I2> && indirect_relation<C, projected<I1, P1>, projected<I2, P2>>`

## ◆ mismatch() [3/3]

template<typename Rng1 , typename Rng2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>

mismatch_result<borrowed_iterator_t<Rng1>, borrowed_iterator_t<Rng2> > ranges::mismatch | ( | Rng1 && | rng1,
|  | Rng2 && | rng2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/mismatch.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng1> && input_range<Rng2> && indirect_relation<C, projected<iterator_t<Rng1>, P1>, projected<iterator_t<Rng2>, P2>>`

## ◆ move() [1/2]

template<typename I , typename S , typename O >

move_result<I, O> ranges::move | ( | I | first,
|  | S | last,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/move.hpp>`

function template `move`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && weakly_incrementable<O> && indirectly_movable<I, O>`

## ◆ move() [2/2]

template<typename Rng , typename O >

move_result<borrowed_iterator_t<Rng>, O> ranges::move | ( | Rng && | rng,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/move.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && weakly_incrementable<O> && indirectly_movable<iterator_t<Rng>, O>`

## ◆ move_backward() [1/2]

template<typename I , typename S , typename O >

move_backward_result<I, O> ranges::move_backward | ( | I | first,
|  | S | end_,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/move_backward.hpp>`

function template `move_backward`

Precondition
  requires `bidirectional_iterator<I> && sentinel_for<S, I> && bidirectional_iterator<O> && indirectly_movable<I, O>`

## ◆ move_backward() [2/2]

template<typename Rng , typename O >

move_backward_result<borrowed_iterator_t<Rng>, O> ranges::move_backward | ( | Rng && | rng,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/move_backward.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `bidirectional_range<Rng> && bidirectional_iterator<O> && indirectly_movable<iterator_t<Rng>, O>`

## ◆ next_permutation() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

bool ranges::next_permutation | ( | I | first,
|  | S | end_,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/permutation.hpp>`

function template `next_permutation`

Precondition
  requires `bidirectional_iterator<I> && sentinel_for<S, I> && sortable<I, C, P>`

## ◆ next_permutation() [2/2]

template<typename Rng , typename C = less, typename P = identity>

bool ranges::next_permutation | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/permutation.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `bidirectional_range<Rng> && sortable<iterator_t<Rng>, C, P>`

References iter_swap.

## ◆ none_of() [1/2]

template<typename I , typename S , typename F , typename P = identity>

bool ranges::none_of | ( | I | first,
|  | S | last,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/none_of.hpp>`

function template `none_of`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_unary_predicate<F, projected<I, P>>`

## ◆ none_of() [2/2]

template<typename Rng , typename F , typename P = identity>

bool ranges::none_of | ( | Rng && | rng,
|  | F | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/none_of.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_unary_predicate<F, projected<iterator_t<Rng>, P>>`

## ◆ nth_element() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::nth_element | ( | I | first,
|  | I | nth,
|  | S | end_,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/nth_element.hpp>`

function template `nth_element`

Precondition
  requires `random_access_iterator<I> && sortable<I, C, P>`

## ◆ nth_element() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::nth_element | ( | Rng && | rng,
|  | iterator_t< Rng > | nth,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/nth_element.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `random_access_range<Rng> && sortable<iterator_t<Rng>, C, P>`

## ◆ partial_sort() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::partial_sort | ( | I | first,
|  | I | middle,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/partial_sort.hpp>`

function template `partial_sort`

Precondition
  requires `sortable<I, C, P> && random_access_iterator<I> && sentinel_for<S, I>`

References ranges::partial_sort().

## ◆ partial_sort() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::partial_sort | ( | Rng && | rng,
|  | iterator_t< Rng > | middle,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/partial_sort.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `sortable<iterator_t<Rng>, C, P> && random_access_range<Rng>`

References iter_swap, and ranges::ref.

Referenced by ranges::partial_sort().

## ◆ partial_sort_copy() [1/2]

template<typename I , typename SI , typename O , typename SO , typename C = less, typename PI = identity, typename PO = identity>

O ranges::partial_sort_copy | ( | I | first,
|  | SI | last,
|  | O | out_begin,
|  | SO | out_end,
|  | C | pred = `C{}`,
|  | PI | in_proj = `PI{}`,
|  | PO | out_proj = `PO{}`
| ) |  |

`#include <range/v3/algorithm/partial_sort_copy.hpp>`

function template `partial_sort_copy`

Precondition
  requires `input_iterator<I> && sentinel_for<SI, I> && random_access_iterator<O> && sentinel_for<SO, O> && indirectly_copyable<I, O> && sortable<O, C, PO> && indirect_strict_weak_order<C, projected<I, PI>, projected<O, PO>>`

References ranges::partial_sort_copy().

## ◆ partial_sort_copy() [2/2]

template<typename InRng , typename OutRng , typename C = less, typename PI = identity, typename PO = identity>

borrowed_iterator_t<OutRng> ranges::partial_sort_copy | ( | InRng && | in_rng,
|  | OutRng && | out_rng,
|  | C | pred = `C{}`,
|  | PI | in_proj = `PI{}`,
|  | PO | out_proj = `PO{}`
| ) |  |

`#include <range/v3/algorithm/partial_sort_copy.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<InRng> && random_access_range<OutRng> && indirectly_copyable<iterator_t<InRng>, iterator_t<OutRng>> && sortable<iterator_t<OutRng>, C, PO> && indirect_strict_weak_order<C, projected<iterator_t<InRng>, PI>, projected<iterator_t<OutRng>, PO>>`

References ranges::make_heap(), ranges::ref, and ranges::sort_heap().

Referenced by ranges::partial_sort_copy().

## ◆ partition() [1/2]

template<typename I , typename S , typename C , typename P = identity>

I ranges::partition | ( | I | first,
|  | S | last,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/partition.hpp>`

function template `partition`

Precondition
  requires `permutable<I> && sentinel_for<S, I> && indirect_unary_predicate<C, projected<I, P>>`

## ◆ partition() [2/2]

template<typename Rng , typename C , typename P = identity>

borrowed_iterator_t<Rng> ranges::partition | ( | Rng && | rng,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/partition.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && permutable<iterator_t<Rng>> && indirect_unary_predicate<C, projected<iterator_t<Rng>, P>>`

## ◆ partition_copy() [1/2]

template<typename I , typename S , typename O0 , typename O1 , typename C , typename P = identity>

partition_copy_result<I, O0, O1> ranges::partition_copy | ( | I | first,
|  | S | last,
|  | O0 | o0,
|  | O1 | o1,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/partition_copy.hpp>`

function template `partition_copy`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && weakly_incrementable<O0> && weakly_incrementable<O1> && indirectly_copyable<I, O0> && indirectly_copyable<I, O1> && indirect_unary_predicate<C, projected<I, P>>`

## ◆ partition_copy() [2/2]

template<typename Rng , typename O0 , typename O1 , typename C , typename P = identity>

partition_copy_result<borrowed_iterator_t<Rng>, O0, O1> ranges::partition_copy | ( | Rng && | rng,
|  | O0 | o0,
|  | O1 | o1,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/partition_copy.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && weakly_incrementable<O0> && weakly_incrementable<O1> && indirectly_copyable<iterator_t<Rng>, O0> && indirectly_copyable<iterator_t<Rng>, O1> && indirect_unary_predicate<C, projected<iterator_t<Rng>, P>>`

## ◆ partition_point() [1/2]

template<typename I , typename S , typename C , typename P = identity>

I ranges::partition_point | ( | I | first,
|  | S | last,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/partition_point.hpp>`

function template `partition_point`

Precondition
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_unary_predicate<C, projected<I, P>>`

Referenced by ranges::lower_bound().

## ◆ partition_point() [2/2]

template<typename Rng , typename C , typename P = identity>

borrowed_iterator_t<Rng> ranges::partition_point | ( | Rng && | rng,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/partition_point.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_unary_predicate<C, projected<iterator_t<Rng>, P>>`

## ◆ pop_heap() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::pop_heap | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

function template `pop_heap`

Precondition
  requires `random_access_iterator<I> && sentinel_for<S, I> && sortable<I, C, P>`

## ◆ pop_heap() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::pop_heap | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `random_access_range<Rng> && sortable<iterator_t<Rng>, C, P>`

## ◆ prev_permutation() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

bool ranges::prev_permutation | ( | I | first,
|  | S | end_,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/permutation.hpp>`

function template `prev_permutation`

Precondition
  requires `bidirectional_iterator<I> && sentinel_for<S, I> && sortable<I, C, P>`

## ◆ prev_permutation() [2/2]

template<typename Rng , typename C = less, typename P = identity>

bool ranges::prev_permutation | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/permutation.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `bidirectional_range<Rng> && sortable<iterator_t<Rng>, C, P>`

References iter_swap.

## ◆ push_heap() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::push_heap | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

function template `push_heap`

Precondition
  requires `random_access_iterator<I> && sentinel_for<S, I> && sortable<I, C, P>`

## ◆ push_heap() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::push_heap | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `random_access_range<Rng> && sortable<iterator_t<Rng>, C, P>`

## ◆ remove() [1/2]

template<typename I , typename S , typename T , typename P = identity>

I ranges::remove | ( | I | first,
|  | S | last,
|  | T const & | val,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/remove.hpp>`

function template `remove`

Precondition
  requires `permutable<I> && sentinel_for<S, I> && indirect_relation<equal_to, projected<I, P>, T const *>`

## ◆ remove() [2/2]

template<typename Rng , typename T , typename P = identity>

borrowed_iterator_t<Rng> ranges::remove | ( | Rng && | rng,
|  | T const & | val,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/remove.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && permutable<iterator_t<Rng>> && indirect_relation<equal_to, projected<iterator_t<Rng>, P>, T const *>`

## ◆ remove_copy() [1/2]

template<typename I , typename S , typename O , typename T , typename P = identity>

remove_copy_result<I, O> ranges::remove_copy | ( | I | first,
|  | S | last,
|  | O | out,
|  | T const & | val,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/remove_copy.hpp>`

function template `remove_copy`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && weakly_incrementable<O> && indirect_relation<equal_to, projected<I, P>, T const *> && indirectly_copyable<I, O>`

## ◆ remove_copy() [2/2]

template<typename Rng , typename O , typename T , typename P = identity>

remove_copy_result<borrowed_iterator_t<Rng>, O> ranges::remove_copy | ( | Rng && | rng,
|  | O | out,
|  | T const & | val,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/remove_copy.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && weakly_incrementable<O> && indirect_relation<equal_to, projected<iterator_t<Rng>, P>, T const *> && indirectly_copyable<iterator_t<Rng>, O>`

## ◆ remove_copy_if() [1/2]

template<typename I , typename S , typename O , typename C , typename P = identity>

remove_copy_if_result<I, O> ranges::remove_copy_if | ( | I | first,
|  | S | last,
|  | O | out,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/remove_copy_if.hpp>`

function template `remove_copy_if`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && weakly_incrementable<O> && indirect_unary_predicate<C, projected<I, P>> && indirectly_copyable<I, O>`

## ◆ remove_copy_if() [2/2]

template<typename Rng , typename O , typename C , typename P = identity>

remove_copy_if_result<borrowed_iterator_t<Rng>, O> ranges::remove_copy_if | ( | Rng && | rng,
|  | O | out,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/remove_copy_if.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && weakly_incrementable<O> && indirect_unary_predicate<C, projected<iterator_t<Rng>, P>> && indirectly_copyable<iterator_t<Rng>, O>`

## ◆ remove_if() [1/2]

template<typename I , typename S , typename C , typename P = identity>

I ranges::remove_if | ( | I | first,
|  | S | last,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/remove_if.hpp>`

function template `remove_if`

Precondition
  requires `permutable<I> && sentinel_for<S, I> && indirect_unary_predicate<C, projected<I, P>>`

## ◆ remove_if() [2/2]

template<typename Rng , typename C , typename P = identity>

borrowed_iterator_t<Rng> ranges::remove_if | ( | Rng && | rng,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/remove_if.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && permutable<iterator_t<Rng>> && indirect_unary_predicate<C, projected<iterator_t<Rng>, P>>`

## ◆ replace() [1/2]

template<typename I , typename S , typename T1 , typename T2 , typename P = identity>

I ranges::replace | ( | I | first,
|  | S | last,
|  | T1 const & | old_value,
|  | T2 const & | new_value,
|  | P | proj = `{}`
| ) |  |

`#include <range/v3/algorithm/replace.hpp>`

function template `replace`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && indirectly_writable<I, T2 const &> && indirect_relation<equal_to, projected<I, P>, T1 const *>`

## ◆ replace() [2/2]

template<typename Rng , typename T1 , typename T2 , typename P = identity>

borrowed_iterator_t<Rng> ranges::replace | ( | Rng && | rng,
|  | T1 const & | old_value,
|  | T2 const & | new_value,
|  | P | proj = `{}`
| ) |  |

`#include <range/v3/algorithm/replace.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirectly_writable<iterator_t<Rng>, T2 const &> && indirect_relation<equal_to, projected<iterator_t<Rng>, P>, T1 const *>`

## ◆ replace_copy() [1/2]

template<typename I , typename S , typename O , typename T1 , typename T2 , typename P = identity>

replace_copy_result<I, O> ranges::replace_copy | ( | I | first,
|  | S | last,
|  | O | out,
|  | T1 const & | old_value,
|  | T2 const & | new_value,
|  | P | proj = `{}`
| ) |  |

`#include <range/v3/algorithm/replace_copy.hpp>`

function template `replace_copy`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && output_iterator<O, T2 const &> && indirectly_copyable<I, O> && indirect_relation<equal_to, projected<I, P>, T1 const *>`

## ◆ replace_copy() [2/2]

template<typename Rng , typename O , typename T1 , typename T2 , typename P = identity>

replace_copy_result<borrowed_iterator_t<Rng>, O> ranges::replace_copy | ( | Rng && | rng,
|  | O | out,
|  | T1 const & | old_value,
|  | T2 const & | new_value,
|  | P | proj = `{}`
| ) |  |

`#include <range/v3/algorithm/replace_copy.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && output_iterator<O, T2 const &> && indirectly_copyable<iterator_t<Rng>, O> && indirect_relation<equal_to, projected<iterator_t<Rng>, P>, T1 const *>`

## ◆ replace_copy_if() [1/2]

template<typename I , typename S , typename O , typename C , typename T , typename P = identity>

replace_copy_if_result<I, O> ranges::replace_copy_if | ( | I | first,
|  | S | last,
|  | O | out,
|  | C | pred,
|  | T const & | new_value,
|  | P | proj = `{}`
| ) |  |

`#include <range/v3/algorithm/replace_copy_if.hpp>`

function template `replace_copy_if`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && output_iterator<O, T const &> && indirect_unary_predicate<C, projected<I, P>> && indirectly_copyable<I, O>`

## ◆ replace_copy_if() [2/2]

template<typename Rng , typename O , typename C , typename T , typename P = identity>

replace_copy_if_result<borrowed_iterator_t<Rng>, O> ranges::replace_copy_if | ( | Rng && | rng,
|  | O | out,
|  | C | pred,
|  | T const & | new_value,
|  | P | proj = `{}`
| ) |  |

`#include <range/v3/algorithm/replace_copy_if.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && output_iterator<O, T const &> && indirect_unary_predicate<C, projected<iterator_t<Rng>, P>> && indirectly_copyable<iterator_t<Rng>, O>`

## ◆ replace_if() [1/2]

template<typename I , typename S , typename C , typename T , typename P = identity>

I ranges::replace_if | ( | I | first,
|  | S | last,
|  | C | pred,
|  | T const & | new_value,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/replace_if.hpp>`

function template `replace_if`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_unary_predicate<C, projected<I, P>> && indirectly_writable<I, T const &>`

## ◆ replace_if() [2/2]

template<typename Rng , typename C , typename T , typename P = identity>

borrowed_iterator_t<Rng> ranges::replace_if | ( | Rng && | rng,
|  | C | pred,
|  | T const & | new_value,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/replace_if.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_unary_predicate<C, projected<iterator_t<Rng>, P>> && indirectly_writable<iterator_t<Rng>, T const &>`

## ◆ reverse() [1/2]

template<typename I , typename S >

I ranges::reverse | ( | I | first,
|  | S | end_
| ) |  |

`#include <range/v3/algorithm/reverse.hpp>`

function template `reverse`

Precondition
  requires `bidirectional_iterator<I> && sentinel_for<S, I> && permutable<I>`

## ◆ reverse() [2/2]

template<typename Rng , typename I = iterator_t<Rng>>

borrowed_iterator_t<Rng> ranges::reverse | ( | Rng && | rng | ) |

`#include <range/v3/algorithm/reverse.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `bidirectional_range<Rng> && permutable<I>`

## ◆ reverse_copy() [1/2]

template<typename I , typename S , typename O >

reverse_copy_result<I, O> ranges::reverse_copy | ( | I | first,
|  | S | end_,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/reverse_copy.hpp>`

function template `reverse_copy`

Precondition
  requires `bidirectional_iterator<I> && sentinel_for<S, I> && weakly_incrementable<O> && indirectly_copyable<I, O>`

## ◆ reverse_copy() [2/2]

template<typename Rng , typename O >

reverse_copy_result<borrowed_iterator_t<Rng>, O> ranges::reverse_copy | ( | Rng && | rng,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/reverse_copy.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `bidirectional_range<Rng> && weakly_incrementable<O> && indirectly_copyable<iterator_t<Rng>, O>`

## ◆ rotate() [1/2]

template<typename I , typename S >

subrange<I> ranges::rotate | ( | I | first,
|  | I | middle,
|  | S | last
| ) |  |

`#include <range/v3/algorithm/rotate.hpp>`

function template `rotate`

Precondition
  requires `permutable<I> && sentinel_for<S, I>`

## ◆ rotate() [2/2]

template<typename Rng , typename I = iterator_t<Rng>>

borrowed_subrange_t<Rng> ranges::rotate | ( | Rng && | rng,
|  | I | middle
| ) |  |

`#include <range/v3/algorithm/rotate.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `range<Rng> && permutable<I>`

## ◆ rotate_copy() [1/2]

template<typename I , typename S , typename O , typename P = identity>

rotate_copy_result<I, O> ranges::rotate_copy | ( | I | first,
|  | I | middle,
|  | S | last,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/rotate_copy.hpp>`

function template `rotate_copy`

Precondition
  requires `forward_iterator<I> && sentinel_for<S, I> && weakly_incrementable<O> && indirectly_copyable<I, O>`

## ◆ rotate_copy() [2/2]

template<typename Rng , typename O , typename P = identity>

rotate_copy_result<borrowed_iterator_t<Rng>, O> ranges::rotate_copy | ( | Rng && | rng,
|  | iterator_t< Rng > | middle,
|  | O | out
| ) |  |

`#include <range/v3/algorithm/rotate_copy.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `range<Rng> && weakly_incrementable<O> && indirectly_copyable<iterator_t<Rng>, O>`

References ranges::aux::copy, and ranges::aux::move.

## ◆ sample() [1/4]

template<typename I , typename S , typename O , typename Gen = detail::default_random_engine &>

sample_result<I, O> ranges::sample | ( | I | first,
|  | S | last,
|  | O | out,
|  | iter_difference_t< O > const | n,
|  | Gen && | gen = `detail::get_random_engine()`
| ) |  |

`#include <range/v3/algorithm/sample.hpp>`

function template `sample`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && weakly_incrementable<O> && indirectly_copyable<I, O> && uniform_random_bit_generator<std::remove_reference_t<Gen>> && (random_access_iterator<O> || forward_iterator<I> || sized_sentinel_for<S, I>)`

## ◆ sample() [2/4]

template<typename I , typename S , typename ORng , typename Gen = detail::default_random_engine &>

sample_result<I, borrowed_iterator_t<ORng> > ranges::sample | ( | I | first,
|  | S | last,
|  | ORng && | out,
|  | Gen && | gen = `detail::get_random_engine()`
| ) |  |

`#include <range/v3/algorithm/sample.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && weakly_incrementable<iterator_t<ORng>> && indirectly_copyable<I, iterator_t<ORng>> && uniform_random_bit_generator<std::remove_reference_t<Gen>> && (forward_range<ORng> || sized_range<ORng>) && (random_access_iterator<iterator_t<ORng>> || forward_iterator<I> || sized_sentinel_for<S, I>)`

## ◆ sample() [3/4]

template<typename IRng , typename ORng , typename Gen = detail::default_random_engine &>

sample_result<borrowed_iterator_t<IRng>, borrowed_iterator_t<ORng> > ranges::sample | ( | IRng && | rng,
|  | ORng && | out,
|  | Gen && | gen = `detail::get_random_engine()`
| ) |  |

`#include <range/v3/algorithm/sample.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<IRng> && range<ORng> && indirectly_copyable<iterator_t<IRng>, iterator_t<ORng>> && uniform_random_bit_generator<std::remove_reference_t<Gen>> && (random_access_iterator<iterator_t<ORng>> || forward_range<IRng> || sized_range<IRng>) && (forward_range<ORng> || sized_range<ORng>)`

References ranges::begin, ranges::distance, ranges::end, and ranges::aux::move.

## ◆ sample() [4/4]

template<typename Rng , typename O , typename Gen = detail::default_random_engine &>

sample_result<borrowed_iterator_t<Rng>, O> ranges::sample | ( | Rng && | rng,
|  | O | out,
|  | iter_difference_t< O > const | n,
|  | Gen && | gen = `detail::get_random_engine()`
| ) |  |

`#include <range/v3/algorithm/sample.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && weakly_incrementable<O> && indirectly_copyable<iterator_t<Rng>, O> && uniform_random_bit_generator<std::remove_reference_t<Gen>> && (random_access_iterator<O> || forward_range<Rng> || sized_range<Rng>)`

## ◆ search() [1/2]

template<typename I1 , typename S1 , typename I2 , typename S2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>

subrange<I1> ranges::search | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | S2 | end2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/search.hpp>`

function template `search`

Precondition
  requires `forward_iterator<I1> && sentinel_for<S1, I1> && forward_iterator<I2> && sentinel_for<S2, I2> && indirectly_comparable<I1, I2, C, P1, P2>`

## ◆ search() [2/2]

template<typename Rng1 , typename Rng2 , typename C = equal_to, typename P1 = identity, typename P2 = identity>

borrowed_subrange_t<Rng1> ranges::search | ( | Rng1 && | rng1,
|  | Rng2 && | rng2,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/search.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng1> && forward_range<Rng2> && indirectly_comparable<iterator_t<Rng1>, iterator_t<Rng2>, C, P1, P2>`

## ◆ search_n() [1/2]

template<typename I , typename S , typename V , typename C = equal_to, typename P = identity>

subrange<I> ranges::search_n | ( | I | first,
|  | S | last,
|  | iter_difference_t< I > | cnt,
|  | V const & | val,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/search_n.hpp>`

function template `search_n`

Precondition
  requires `forward_iterator<I> && sentinel_for<S, I> && indirectly_comparable<I, V const *, C, P>`

## ◆ search_n() [2/2]

template<typename Rng , typename V , typename C = equal_to, typename P = identity>

borrowed_subrange_t<Rng> ranges::search_n | ( | Rng && | rng,
|  | iter_difference_t< iterator_t< Rng >> | cnt,
|  | V const & | val,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/search_n.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirectly_comparable<iterator_t<Rng>, V const *, C, P>`

## ◆ set_difference() [1/2]

template<typename I1 , typename S1 , typename I2 , typename S2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>

set_difference_result<I1, O> ranges::set_difference | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | S2 | end2,
|  | O | out,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/set_algorithm.hpp>`

function template `set_difference`

Precondition
  requires `sentinel_for<S1, I1> && sentinel_for<S2, I2> && mergeable<I1, I2, O, C, P1, P2>`

## ◆ set_difference() [2/2]

template<typename Rng1 , typename Rng2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>

set_difference_result<borrowed_iterator_t<Rng1>, O> ranges::set_difference | ( | Rng1 && | rng1,
|  | Rng2 && | rng2,
|  | O | out,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/set_algorithm.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `range<Rng1> && range<Rng2> && mergeable<iterator_t<Rng1>, iterator_t<Rng2>, O, C, P1, P2>`

## ◆ set_intersection() [1/2]

template<typename I1 , typename S1 , typename I2 , typename S2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>

O ranges::set_intersection | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | S2 | end2,
|  | O | out,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/set_algorithm.hpp>`

function template `set_intersection`

Precondition
  requires `sentinel_for<S1, I1> && sentinel_for<S2, I2> && mergeable<I1, I2, O, C, P1, P2>`

## ◆ set_intersection() [2/2]

template<typename Rng1 , typename Rng2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>

O ranges::set_intersection | ( | Rng1 && | rng1,
|  | Rng2 && | rng2,
|  | O | out,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/set_algorithm.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `range<Rng1> && range<Rng2> && mergeable<iterator_t<Rng1>, iterator_t<Rng2>, O, C, P1, P2>`

References ranges::begin, ranges::end, and ranges::aux::move.

## ◆ set_symmetric_difference() [1/2]

template<typename I1 , typename S1 , typename I2 , typename S2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>

set_symmetric_difference_result<I1, I2, O> ranges::set_symmetric_difference | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | S2 | end2,
|  | O | out,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/set_algorithm.hpp>`

function template `set_symmetric_difference`

Precondition
  requires `sentinel_for<S1, I1> && sentinel_for<S2, I2> && mergeable<I1, I2, O, C, P1, P2>`

## ◆ set_symmetric_difference() [2/2]

template<typename Rng1 , typename Rng2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>

set_symmetric_difference_result<borrowed_iterator_t<Rng1>, borrowed_iterator_t<Rng2>, O> ranges::set_symmetric_difference | ( | Rng1 && | rng1,
|  | Rng2 && | rng2,
|  | O | out,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/set_algorithm.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `range<Rng1> && range<Rng2> && mergeable<iterator_t<Rng1>, iterator_t<Rng2>, O, C, P1, P2>`

## ◆ set_union() [1/2]

template<typename I1 , typename S1 , typename I2 , typename S2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>

set_union_result<I1, I2, O> ranges::set_union | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | S2 | end2,
|  | O | out,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/set_algorithm.hpp>`

function template `set_union`

Precondition
  requires `sentinel_for<S1, I1> && sentinel_for<S2, I2> && mergeable<I1, I2, O, C, P1, P2>`

## ◆ set_union() [2/2]

template<typename Rng1 , typename Rng2 , typename O , typename C = less, typename P1 = identity, typename P2 = identity>

set_union_result<borrowed_iterator_t<Rng1>, borrowed_iterator_t<Rng2>, O> ranges::set_union | ( | Rng1 && | rng1,
|  | Rng2 && | rng2,
|  | O | out,
|  | C | pred = `C{}`,
|  | P1 | proj1 = `P1{}`,
|  | P2 | proj2 = `P2{}`
| ) |  |

`#include <range/v3/algorithm/set_algorithm.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `range<Rng1> && range<Rng2> && mergeable<iterator_t<Rng1>, iterator_t<Rng2>, O, C, P1, P2>`

## ◆ shuffle() [1/2]

template<typename I , typename S , typename Gen = detail::default_random_engine &>

I ranges::shuffle | ( | I const | first,
|  | S const | last,
|  | Gen && | gen = `detail::get_random_engine()`
| ) |  |

`#include <range/v3/algorithm/shuffle.hpp>`

function template `shuffle`

Precondition
  requires `random_access_iterator<I> && sentinel_for<S, I> && permutable<I> && uniform_random_bit_generator<std::remove_reference_t<Gen>> && convertible_to<invoke_result_t<Gen &>, iter_difference_t<I>>`

## ◆ shuffle() [2/2]

template<typename Rng , typename Gen = detail::default_random_engine &>

borrowed_iterator_t<Rng> ranges::shuffle | ( | Rng && | rng,
|  | Gen && | rand = `detail::get_random_engine()`
| ) |  |

`#include <range/v3/algorithm/shuffle.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `random_access_range<Rng> && permutable<iterator_t<Rng>> && uniform_random_bit_generator<std::remove_reference_t<Gen>> && convertible_to<invoke_result_t<Gen &>, iter_difference_t<iterator_t<Rng>>>`

## ◆ sort() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::sort | ( | I | first,
|  | S | end_,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/sort.hpp>`

function template `sort`

Precondition
  requires `sortable<I, C, P> && random_access_iterator<I> && sentinel_for<S, I>`

## ◆ sort() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::sort | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/sort.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `sortable<iterator_t<Rng>, C, P> && random_access_range<Rng>`

References ranges::aux::move, and ranges::next.

## ◆ sort_heap() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::sort_heap | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

Precondition
  requires `random_access_iterator<I> && sentinel_for<S, I> && sortable<I, C, P>`

Referenced by ranges::partial_sort_copy().

## ◆ sort_heap() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::sort_heap | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/heap_algorithm.hpp>`

Precondition
  requires `random_access_range<Rng &> && sortable<iterator_t<Rng>, C, P>`

## ◆ stable_partition() [1/2]

template<typename I , typename S , typename C , typename P = identity>

I ranges::stable_partition | ( | I | first,
|  | S | last,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/stable_partition.hpp>`

function template `stable_partition`

Precondition
  requires `bidirectional_iterator<I> && sentinel_for<S, I> && indirect_unary_predicate<C, projected<I, P>> && permutable<I>`

## ◆ stable_partition() [2/2]

template<typename Rng , typename C , typename P = identity>

borrowed_iterator_t<Rng> ranges::stable_partition | ( | Rng && | rng,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/stable_partition.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `bidirectional_range<Rng> && indirect_unary_predicate<C, projected<iterator_t<Rng>, P>> && permutable<iterator_t<Rng>>`

## ◆ stable_sort() [1/2]

template<typename I , typename S , typename C = less, typename P = identity>

I ranges::stable_sort | ( | I | first,
|  | S | end_,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/stable_sort.hpp>`

function template `stable_sort`

Precondition
  requires `sortable<I, C, P> && random_access_iterator<I> && sentinel_for<S, I>`

## ◆ stable_sort() [2/2]

template<typename Rng , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::stable_sort | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/stable_sort.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `sortable<iterator_t<Rng>, C, P> && random_access_range<Rng>`

## ◆ starts_with() [1/2]

template<typename I1 , typename S1 , typename I2 , typename S2 , typename Comp = equal_to, typename Proj1 = identity, typename Proj2 = identity>

constexpr bool ranges::starts_with | ( | I1 | first1,
|  | S1 | last1,
|  | I2 | first2,
|  | S2 | last2,
|  | Comp | comp = `{}`,
|  | Proj1 | proj1 = `{}`,
|  | Proj2 | proj2 = `{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/starts_with.hpp>`

function template `starts_with`

Precondition
  requires `input_iterator<I1> && sentinel_for<S1, I1> && input_iterator<I2> && sentinel_for<S2, I2> && indirectly_comparable<I1, I2, Comp, Proj1, Proj2>`

## ◆ starts_with() [2/2]

template<typename R1 , typename R2 , typename Comp = equal_to, typename Proj1 = identity, typename Proj2 = identity>

constexpr bool ranges::starts_with | ( | R1 && | r1,
|  | R2 && | r2,
|  | Comp | comp = `{}`,
|  | Proj1 | proj1 = `{}`,
|  | Proj2 | proj2 = `{}`
| ) |  |
| constexpr

`#include <range/v3/algorithm/starts_with.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<R1> && input_range<R2> && indirectly_comparable<iterator_t<R1>, iterator_t<R2>, Comp, Proj1, Proj2>`

## ◆ swap_ranges() [1/4]

template<typename I1 , typename S1 , typename I2 >

swap_ranges_result<I1, I2> ranges::swap_ranges | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2
| ) |  |

`#include <range/v3/algorithm/swap_ranges.hpp>`

function template `swap_ranges`

Precondition
  requires `input_iterator<I1> && sentinel_for<S1, I1> && input_iterator<I2> && indirectly_swappable<I1, I2>`

## ◆ swap_ranges() [2/4]

template<typename I1 , typename S1 , typename I2 , typename S2 >

swap_ranges_result<I1, I2> ranges::swap_ranges | ( | I1 | begin1,
|  | S1 | end1,
|  | I2 | begin2,
|  | S2 | end2
| ) |  |

`#include <range/v3/algorithm/swap_ranges.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_iterator<I1> && sentinel_for<S1, I1> && input_iterator<I2> && sentinel_for<S2, I2> && indirectly_swappable<I1, I2>`

## ◆ swap_ranges() [3/4]

template<typename Rng1 , typename I2_ >

swap_ranges_result<iterator_t<Rng1>, uncvref_t<I2_> > ranges::swap_ranges | ( | Rng1 && | rng1,
|  | I2_ && | begin2
| ) |  |

`#include <range/v3/algorithm/swap_ranges.hpp>`

Precondition
  requires `input_range<Rng1> && input_iterator<uncvref_t<I2_>> && indirectly_swappable<iterator_t<Rng1>, uncvref_t<I2_>>`

## ◆ swap_ranges() [4/4]

template<typename Rng1 , typename Rng2 >

swap_ranges_result<borrowed_iterator_t<Rng1>, borrowed_iterator_t<Rng2> > ranges::swap_ranges | ( | Rng1 && | rng1,
|  | Rng2 && | rng2
| ) |  |

`#include <range/v3/algorithm/swap_ranges.hpp>`

Precondition
  requires `input_range<Rng1> && input_range<Rng2> && indirectly_swappable<iterator_t<Rng1>, iterator_t<Rng2>>`

## ◆ transform() [1/6]

template<typename I , typename S , typename O , typename F , typename P = identity>

unary_transform_result<I, O> ranges::transform | ( | I | first,
|  | S | last,
|  | O | out,
|  | F | fun,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/transform.hpp>`

function template `transform`

Precondition
  requires `input_iterator<I> && sentinel_for<S, I> && weakly_incrementable<O> && copy_constructible<F> && indirectly_writable<O, indirect_result_t<F &, projected<I, P>>>`

## ◆ transform() [2/6]

template<typename I0 , typename S0 , typename I1 , typename O , typename F , typename P0 = identity, typename P1 = identity>

binary_transform_result<I0, I1, O> ranges::transform | ( | I0 | begin0,
|  | S0 | end0,
|  | I1 | begin1,
|  | O | out,
|  | F | fun,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |

`#include <range/v3/algorithm/transform.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_iterator<I0> && sentinel_for<S0, I0> && input_iterator<I1> && weakly_incrementable<O> && copy_constructible<F> && indirectly_writable< O, indirect_result_t<F &, projected<I0, P0>, projected<I1, P1>>>`

## ◆ transform() [3/6]

template<typename I0 , typename S0 , typename I1 , typename S1 , typename O , typename F , typename P0 = identity, typename P1 = identity>

binary_transform_result<I0, I1, O> ranges::transform | ( | I0 | begin0,
|  | S0 | end0,
|  | I1 | begin1,
|  | S1 | end1,
|  | O | out,
|  | F | fun,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |

`#include <range/v3/algorithm/transform.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_iterator<I0> && sentinel_for<S0, I0> && input_iterator<I1> && sentinel_for<S1, I1> && weakly_incrementable<O> && copy_constructible<F> && indirectly_writable< O, indirect_result_t<F &, projected<I0, P0>, projected<I1, P1>>>`

## ◆ transform() [4/6]

template<typename Rng , typename O , typename F , typename P = identity>

unary_transform_result<borrowed_iterator_t<Rng>, O> ranges::transform | ( | Rng && | rng,
|  | O | out,
|  | F | fun,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/transform.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && weakly_incrementable<O> && copy_constructible<F> && indirectly_writable<O, indirect_result_t<F &, projected<iterator_t<Rng>, P>>>`

## ◆ transform() [5/6]

template<typename Rng0 , typename I1Ref , typename O , typename F , typename P0 = identity, typename P1 = identity>

binary_transform_result<borrowed_iterator_t<Rng0>, uncvref_t<I1Ref>, O> ranges::transform | ( | Rng0 && | rng0,
|  | I1Ref && | begin1,
|  | O | out,
|  | F | fun,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |

`#include <range/v3/algorithm/transform.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng0> && input_iterator<uncvref_t<I1Ref>> && weakly_incrementable<O> && copy_constructible<F> && indirectly_writable< O, indirect_result_t<F &, projected<iterator_t<Rng0>, P0>, projected<uncvref_t<I1Ref>, P1>>>`

## ◆ transform() [6/6]

template<typename Rng0 , typename Rng1 , typename O , typename F , typename P0 = identity, typename P1 = identity>

binary_transform_result<borrowed_iterator_t<Rng0>, borrowed_iterator_t<Rng1>, O> ranges::transform | ( | Rng0 && | rng0,
|  | Rng1 && | rng1,
|  | O | out,
|  | F | fun,
|  | P0 | proj0 = `P0{}`,
|  | P1 | proj1 = `P1{}`
| ) |  |

`#include <range/v3/algorithm/transform.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng0> && input_range<Rng1> && weakly_incrementable<O> && copy_constructible<F> && indirectly_writable< O, indirect_result_t<F &, projected<iterator_t<Rng0>, P0>, projected<iterator_t<Rng1>, P1>>>`

## ◆ unique() [1/2]

template<typename I , typename S , typename C = equal_to, typename P = identity>

I ranges::unique | ( | I | first,
|  | S | last,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/unique.hpp>`

template function `unique`

range-based version of the `unique` std algorithm

Precondition
  `Rng` is a model of the `forward_range` concept
  `I` is a model of the `forward_iterator` concept
  `S` is a model of the `sentinel_for` concept
  `C` is a model of the `relation` concept
  requires `sortable<I, C, P> && sentinel_for<S, I>`

## ◆ unique() [2/2]

template<typename Rng , typename C = equal_to, typename P = identity>

borrowed_iterator_t<Rng> ranges::unique | ( | Rng && | rng,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/unique.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `sortable<iterator_t<Rng>, C, P> && range<Rng>`

## ◆ unique_copy() [1/2]

template<typename I , typename S , typename O , typename C = equal_to, typename P = identity>

unique_copy_result<I, O> ranges::unique_copy | ( | I | first,
|  | S | last,
|  | O | out,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/unique_copy.hpp>`

template function unique_copy

range-based version of the `unique_copy` std algorithm

Precondition
  `Rng` is a model of the `input_range` concept
  `O` is a model of the `weakly_incrementable` concept
  `C` is a model of the `relation` concept
  requires `input_iterator<I> && sentinel_for<S, I> && indirect_relation<C, projected<I, P>> && weakly_incrementable<O> && indirectly_copyable<I, O> && (forward_iterator<I> || forward_iterator<O> || indirectly_copyable_storable<I, O>)` //

## ◆ unique_copy() [2/2]

template<typename Rng , typename O , typename C = equal_to, typename P = identity>

unique_copy_result<borrowed_iterator_t<Rng>, O> ranges::unique_copy | ( | Rng && | rng,
|  | O | out,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/unique_copy.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `input_range<Rng> && indirect_relation<C, projected<iterator_t<Rng>, P>> && weakly_incrementable<O> && indirectly_copyable<iterator_t<Rng>, O> && (forward_iterator<iterator_t<Rng>> || forward_iterator<O> || indirectly_copyable_storable<iterator_t<Rng>, O>)` //

## ◆ unstable_remove_if() [1/2]

template<typename I , typename C , typename P = identity>

I ranges::unstable_remove_if | ( | I | first,
|  | I | last,
|  | C | pred,
|  | P | proj = `{}`
| ) |  |

`#include <range/v3/algorithm/unstable_remove_if.hpp>`

unstable_remove have O(1) complexity for each element remove, unlike remove O(n) [for worst case]. Each erased element overwritten (moved in) with last one. unstable_remove_if does not preserve relative element order.

function template `unstable_remove_if`

Precondition
  requires `bidirectional_iterator<I> && permutable<I> && indirect_unary_predicate<C, projected<I, P>>`

## ◆ unstable_remove_if() [2/2]

template<typename Rng , typename C , typename P = identity>

borrowed_iterator_t<Rng> ranges::unstable_remove_if | ( | Rng && | rng,
|  | C | pred,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/unstable_remove_if.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `bidirectional_range<Rng> && common_range<Rng> && permutable<iterator_t<Rng>> && indirect_unary_predicate<C, projected<iterator_t<Rng>, P>>`

## ◆ upper_bound() [1/2]

template<typename I , typename S , typename V , typename C = less, typename P = identity>

I ranges::upper_bound | ( | I | first,
|  | S | last,
|  | V const & | val,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/upper_bound.hpp>`

function template `upper_bound`

Precondition
  requires `forward_iterator<I> && sentinel_for<S, I> && indirect_strict_weak_order<C, V const *, projected<I, P>>`

## ◆ upper_bound() [2/2]

template<typename Rng , typename V , typename C = less, typename P = identity>

borrowed_iterator_t<Rng> ranges::upper_bound | ( | Rng && | rng,
|  | V const & | val,
|  | C | pred = `C{}`,
|  | P | proj = `P{}`
| ) |  |

`#include <range/v3/algorithm/upper_bound.hpp>`

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Precondition
  requires `forward_range<Rng> && indirect_strict_weak_order<C, V const *, projected<iterator_t<Rng>, P>>`