C# List of objects, how do I get the sum of a property

using System.Linq;

double total = myList.Sum(item => item.Amount);

Leave a Comment