The group by
and into
keywords provide grouping constructs to organize elements of the input sequence into buckets.
This sample demonstrates the use of group by
and into
to create buckets based on the remainder of an integer when dividing it by 5.
This sample uses group by
to partition a list of words by their first letter.
This sample uses group by
to partition a list of products by category.
This sample demonstrates the use of group by
and into
nested buckets of orders by customer, year, and month. The result
Next: Grouping with a custom comparer » Previous: Nested custom comparisons «