it looks fairly simple but I can not get my mind over it.
I have a list:
List<IGrouping<byte, MyClass>>
MyClass object has a timestamp property, and I also have list of timestamp, now I want to know if there is elegant way to get all values from grouping list where Timestamp property is in my timestamp list?
I have solved the problem, but i think it can be solved in more efficient way. code would look like:
var loadedValues = new List<MyClass>();
foreach (IGrouping<byte, MyClass> value in Values)
{
loadedValues.AddRange(value.Select(c => c).Where(c => Timestamps.Any(point => c.Timestamp == point)));
}