tetl 0.1.0
Embedded Template Library
Loading...
Searching...
No Matches
binary_search.hpp File Reference

Go to the source code of this file.

Namespaces

namespace  etl
 

Functions

template<typename ForwardIt, typename T>
constexpr auto binary_search (ForwardIt first, ForwardIt last, T const &value) -> bool
 Checks if an element equivalent to value appears within the range [first, last). For binary_search to succeed, the range [first, last) must be at least partially ordered with respect to value.
 
template<typename ForwardIt, typename T, typename Compare>
constexpr auto binary_search (ForwardIt first, ForwardIt last, T const &value, Compare comp) -> bool
 Checks if an element equivalent to value appears within the range [first, last). For binary_search to succeed, the range [first, last) must be at least partially ordered with respect to value.