Enumerable::SequenceEqual<TSource> Method (IEnumerable<TSource>^, IEnumerable<TSource>^, IEqualityComparer<TSource>^)
Determines whether two sequences are equal by comparing their elements by using a specified IEqualityComparer<T>.
Assembly: System.Core (in System.Core.dll)
public: generic<typename TSource> [ExtensionAttribute] static bool SequenceEqual( IEnumerable<TSource>^ first, IEnumerable<TSource>^ second, IEqualityComparer<TSource>^ comparer )
An IEnumerable<T> to compare to the first sequence.
Return ValueType: System::Boolean
true if the two source sequences are of equal length and their corresponding elements compare equal according to comparer; otherwise, false.
The type of the elements of the input sequences.
The following example shows how to implement an equality comparer that can be used in themethod.
After you implement this comparer, you can use sequences of Product objects in the method, as shown in the following example.
Available since 4.5
Available since 3.5
Portable Class Library
Supported in: portable .NET platforms
Available since 2.0
Windows Phone Silverlight
Available since 7.0
Available since 8.1