I'm looking to do a GroupBy and a Select in Linq, but the following doesn't compile:
foreach (string fooName in fooList.GroupBy(f => f.Name).Select(f => f.Name)) { ... } Why am I unable to use f => f.name in my Select clause? More importantly, is there any way around this?