Using CountBy and AggregateBy in C# 13 / .NET 9

It’s great to see Microsoft still giving us new things in LINQ. With C# 13 / .NET 9, we get CountBy and AggregateBy, so let’s see how to use them.

  Dec 3, 2024 (rev. Sep 16, 2025) ·  5 min