public static bool HasDuplicates <T>(this IEnumerable <T> source) { if (source == null) { throw new ArgumentNullException(nameof(source)); } return(source.HasDuplicates(EqualityComparer <T> .Default)); }
public static bool HasDuplicates <T>(this IEnumerable <T> enumerable) { return(enumerable.HasDuplicates(e => e)); }