I have two extension functions:
public static IEnumerable<char> Range(char start, char end) { return Enumerable.Range((int)start, (int)end - (int)start + 1).Select(i => (char)i); }
which creates a range of characters, and
public static bool In(this string source, IEnumerable<string> collection) { return collection.Contains(source); }
which is just the opposite of Contains , mainly for readability.
Together I can do:
where elements[0].In(Range('a', 'f')))
source share