Click or drag to resize

CollectionExtensionsMaxByTSource, TKey Method (IEnumerableTSource, FuncTSource, TKey)

Finds the minimum element in the source as scored by its projection.

Namespace:  Gamelogic.Extensions.Algorithms
Assembly:  Assembly-CSharp (in Assembly-CSharp.dll) Version: 0.0.0.0
Syntax
C#
public static TSource MaxBy<TSource, TKey>(
	this IEnumerable<TSource> source,
	Func<TSource, TKey> selector
)

Parameters

source
Type: System.Collections.GenericIEnumerableTSource
selector
Type: SystemFuncTSource, TKey

Type Parameters

TSource
TKey

Return Value

Type: TSource

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IEnumerableTSource. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also