Click or drag to resize

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.Core
Assembly: NMath (in NMath.dll) Version: 7.4
Syntax
public static T KthSmallestValue<T>(
	T[] a,
	int k
)
where T : Object, 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

T
See Also