Navigation
API > API/Runtime > API/Runtime/Core > API/Runtime/Core/Algo > API/Runtime/Core/Algo/Algo__UpperBound
References
| Module | Core |
| Header | /Engine/Source/Runtime/Core/Public/Algo/BinarySearch.h |
| Include | #include "Algo/BinarySearch.h" |
namespace Algo
{
template<typename RangeType, typename ValueType, typename SortPredicateType>
auto Algo&58;&58;UpperBound
&40;
RangeType & Range,
const ValueType & Value,
SortPredicateType SortPredicate
&41;
}
Remarks
Performs binary search, resulting in position of the first element > Value using predicate Position of the first element > Value, may be past end of range
Parameters
| Name | Description |
|---|---|
| Range | Range to search through, must be already sorted by SortPredicate |
| Value | Value to look for |
| SortPredicate | Predicate for sort comparison, defaults to < |