Share via


Extensions.MaxBy<T,R> Method

Definition

public static T MaxBy<T,R> (this System.Collections.Generic.IEnumerable<T> items, Func<T,R> selectRank, System.Collections.Generic.IComparer<R> comparer = default);
static member MaxBy : seq<'T> * Func<'T, 'R> * System.Collections.Generic.IComparer<'R> -> 'T
<Extension()>
Public Function MaxBy(Of T, R) (items As IEnumerable(Of T), selectRank As Func(Of T, R), Optional comparer As IComparer(Of R) = Nothing) As T

Type Parameters

T
R

Parameters

items
IEnumerable<T>
selectRank
Func<T,R>
comparer
IComparer<R>

Returns

T

Applies to