using System.Collections.Generic;
public static void Main()
List<int> list1 = new List<int>{1, 2, 3, 4, 5, 6};
List<int> list2 = new List<int>{1, 2, 3};
List<int> list3 = new List<int>{1, 2};
var lists = new IEnumerable<int>[]{list1, list2, list3};
var commons = ExistsInAll(lists);
Console.WriteLine("Common integers:");
foreach (var c in commons)
static IEnumerable<int> ExistsInAll(IEnumerable<int>[] lists)
HashSet<int> hs = new HashSet<int>(lists.First());
for (int i = 1; i < lists.Length; i++)
hs.IntersectWith(lists[i]);