Aggregate data grouped by a key
I'm looking to aggregate these data:
my current approach iterates over the list into a dictionary and check for duplicate keys. i have a feeling it can be done in a cleaner way with System.Linq stuff
4 Replies
.GroupBy()
with .Select()
and .Sum()
could workAngius
REPL Result: Success
Result: List<Item>
Compile: 588.693ms | Execution: 99.162ms | React with ❌ to remove this embed.
'Ere
oh thanks