If I understand your question, you could use the Any
and Contains
methods like this:
Predicate<Product> ProductFinder = p =>
DataManager.Instance.CurrentSettings.Regions.Any(r => p.regions.Contains(r))
Or you could use the Intersect
and Any
methods like this:
Predicate<Product> ProductFinder = p =>
DataManager.Instance.CurrentSettings.Regions.Intersect(p.regions).Any()
For your updated question, if you want to test if a single string in the list, just use Contains
by itself:
Predicate<Salesplay> SalesplayFinder = p =>
DataManager.Instance.CurrentSettings.Regions.Contains(p.region)