Click or drag to resize
AlgorithmsMinimumT Method (IEnumerableT)
Finds the minimum value in a collection.

Namespace: X3Platform.Collections
Assembly: X3Platform.Support (in X3Platform.Support.dll) Version: 1.0.0.0 (2.0.0.0)
Syntax
public static T Minimum<T>(
	IEnumerable<T> collection
)
where T : Object, IComparable<T>

Parameters

collection
Type: System.Collections.GenericIEnumerableT
The collection to search.

Type Parameters

T
The type of items in the collection.

Return Value

Type: T
The smallest item in the collection.
Exceptions
ExceptionCondition
InvalidOperationExceptionThe collection is empty.
ArgumentNullExceptioncollection is null.
Remarks
Values in the collection are compared by using the IComparable<T> interfaces implementation on the type T.
See Also