foreach(var someClass in SomeClassList) { var someList = someClass.FooList.Select(x => x.Name); if(String.Join(",",someList.Intersect(testList)).OrderBy(x=>x).ToString().ToLowerInvariant() == String.Join(",",someList.OrderBy(x=>x)).ToString().ToLowerInvariant()) { /* do the things */ } }