Sequence Sum TSource  Method (ISequence TSource , Func TSource, BigInteger )A Sandcastle Documented Class Library
Computes the sum of the sequence of BigInteger values that are obtained by invoking a transform function on each element of the input sequence. If the source sequence represents an infinite set or series, this will never return!

Namespace: Sequences
Assembly: Sequences (in Sequences.dll) Version: 1.0.1.0 (1.0.1)
Syntax
public static BigInteger Sum<TSource>(
	this ISequence<TSource> source,
	Func<TSource, BigInteger> selector
)

Parameters

source
Type: Sequences ISequence TSource 
A sequence of values that are used to calculate a sum.
selector
Type: System Func TSource, BigInteger 
Type Parameters
TSource
The type of the elements of source.

Return Value

Type: BigInteger
A transform function to apply to each element.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type ISequence TSource . 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