Click or drag to resize
IEnumerableExtensionsShuffleT Method
Shuffles the elements of a sequence.

Namespace: Bio.Util
Assembly: Bio.Core (in Bio.Core.dll) Version: 2.0.0.1 (2.0.0.1)
Syntax
public static List<T> Shuffle<T>(
	this IEnumerable<T> sequence,
	Random random
)

Parameters

sequence
Type: System.Collections.GenericIEnumerableT
The sequence of elements to shuffle
random
Type: SystemRandom
a random number instance

Type Parameters

T
the type of the elements in the sequence

Return Value

Type: ListT
a list of shuffled items

Usage Note

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