Mega Code Archive

 
Categories / C# Book / 04 LINQ
 

0519 EqualAll - 2

public void Linq97() { var wordsA = new string[] { "cherry", "apple", "blueberry" }; var wordsB = new string[] { "apple", "blueberry", "cherry" }; bool match = wordsA.SequenceEqual(wordsB); Console.WriteLine("The sequences match: {0}", match); } Result The sequences match: False