Check out example codes for "check two lists are equal c#". It will help you in understanding the concepts better.

Code Example 1

List<int> list1 = new List<int> { 1, 2, 3 };
List<int> list2 = new List<int> { 1, 2, 3 };

if (list1.SequenceEqual(list2))
{
  Console.WriteLine("true");
}
else
{
  Console.WriteLine("false");
}

Learn ReactJs, React Native from akashmittal.com