Calc.LowerBound<T> Method

Returns the lower bound of lst seaching for a. lst must be sorted.
public static int LowerBound<T>( 
   List<T> lst
   T a 
   where T : IComparable

Type Parameters

T

Parameters

lst
List<T>

a
T

Return Value

int

The index to the first element larger or equal to a. If a is larger than all elements then -1 is returned.

.NET Framework

Supported in: 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8

In this article

Definition