ArrayMath.Sum<T>(IEnumerable<T>) Method

Computes the sum of the sequence of values.

Definition

Namespace: Extreme.Mathematics
Assembly: Extreme.Numerics (in Extreme.Numerics.dll) Version: 8.1.23
C#
public static T Sum<T>(
	this IEnumerable<T> source
)

Parameters

source  IEnumerable<T>
A sequence of values.

Type Parameters

T
The element type of source.

Return Value

T

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IEnumerable<T>. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

See Also