Skip to content
This repository was archived by the owner on Jan 14, 2025. It is now read-only.

Latest commit

 

History

History
35 lines (20 loc) · 1.25 KB

aggregates-2.md

File metadata and controls

35 lines (20 loc) · 1.25 KB

LINQ - Aggregators

Aggregator methods return a single value calculated from all the elements in a sequence. the aggregator methods include Count, Sum, Min, Max, Average, and Aggregate.

Find the minimum of a sequence of elements

This sample uses Min to get the lowest number in an array.

Find the minimum of a projection

This sample uses Min to get the length of the shortest word in an array.

Find the minimum in each group

This sample uses Min to get the cheapest price among each category's products.

Find all elements matching the minimum

This sample uses Min to get the products with the cheapest price in each category.

Next: Aggregates-Max » Previous: Aggregates-Sum »

Home