dit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_partition&action=edit)  
[ ranges::partition_copy  ](/w/cpp/algorithm/ranges/partition_copy "cpp/algorithm/ranges/partition copy") (C++20)  |  copies a range dividing the elements into two groups   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_partition_copy&action=edit)  
[ ranges::stable_partition  ](/w/cpp/algorithm/ranges/stable_partition "cpp/algorithm/ranges/stable partition") (C++20)  |  divides elements into two groups while preserving their relative order   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_stable_partition&action=edit)  
[ ranges::partition_point  ](/w/cpp/algorithm/ranges/partition_point "cpp/algorithm/ranges/partition point") (C++20)  |  locates the partition point of a partitioned range   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_partition_point&action=edit)  
  
#####  Sorting operations  
  
[ ranges::is_sorted  ](/w/cpp/algorithm/ranges/is_sorted "cpp/algorithm/ranges/is sorted") (C++20)  |  checks whether a range is sorted into ascending order   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_is_sorted&action=edit)  
[ ranges::is_sorted_until  ](/w/cpp/algorithm/ranges/is_sorted_until "cpp/algorithm/ranges/is sorted until") (C++20)  |  finds the largest sorted subrange   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_is_sorted_until&action=edit)  
[ ranges::sort  ](/w/cpp/algorithm/ranges/sort "cpp/algorithm/ranges/sort") (C++20)  |  sorts a range into ascending order   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_sort&action=edit)  
[ ranges::partial_sort  ](/w/cpp/algorithm/ranges/partial_sort "cpp/algorithm/ranges/partial sort") (C++20)  |  sorts the first N elements of a range   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_partial_sort&action=edit)  
[ ranges::partial_sort_copy  ](/w/cpp/algorithm/ranges/partial_sort_copy "cpp/algorithm/ranges/partial sort copy") (C++20)  |  copies and partially sorts a range of elements   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_partial_sort_copy&action=edit)  
[ ranges::stable_sort  ](/w/cpp/algorithm/ranges/stable_sort "cpp/algorithm/ranges/stable sort") (C++20)  |  sorts a range of elements while preserving order between equal elements   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_stable_sort&action=edit)  
[ ranges::nth_element  ](/w/cpp/algorithm/ranges/nth_element "cpp/algorithm/ranges/nth element") (C++20)  |  partially sorts the given range making sure that it is partitioned by the given element   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_nth_element&action=edit)  
  
#####  Binary search operations (on sorted ranges)  
  
[ ranges::lower_bound  ](/w/cpp/algorithm/ranges/lower_bound "cpp/algorithm/ranges/lower bound") (C++20)  |  returns an iterator to the first element _not less_ than the given value   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_lower_bound&action=edit)  
[ ranges::upper_bound  ](/w/cpp/algorithm/ranges/upper_bound "cpp/algorithm/ranges/upper bound") (C++20)  |  returns an iterator to the first element _greater_ than a certain value   
(niebloid)  [ [edit]
](https://en.cppreference.com/mwiki/index.php?title=Template:cpp/algorithm/ranges/dsc_upper_bound&action=edit)  
[ ranges::binary_search  ](/w/cpp/algorithm/ranges/binary_search "cpp/algorithm/ranges/binary s