| NMathFunctionsKthSmallestValueT Method |
Finds the Kth smallest value in the given array. k starts with 0, so
with k = 0, the smallest value is returned, k returns the
second smallest value, and so forth.
Namespace: CenterSpace.NMath.CoreAssembly: NMath (in NMath.dll) Version: 7.4
Syntax public static T KthSmallestValue<T>(
T[] a,
int k
)
where T : Object, IComparable<T>
Public Shared Function KthSmallestValue(Of T As {Object, IComparable(Of T)}) (
a As T(),
k As Integer
) As T
public:
generic<typename T>
where T : Object, IComparable<T>
static T KthSmallestValue(
array<T>^ a,
int k
)
static member KthSmallestValue :
a : 'T[] *
k : int -> 'T when 'T : Object and IComparable<'T>
Parameters
- a T
- An array of T.
- k Int32
- Zero based integer specifing the Kth smallest element.
Type Parameters
- T
- Array data type. Must implement IComparable.
Return Value
TSee Also