Permutation.CreateRandom Method

Creates a new random permutation of the specified length.

Definition

Namespace: Extreme.Mathematics
Assembly: Extreme.Numerics (in Extreme.Numerics.dll) Version: 8.1.23
C#
public static Permutation CreateRandom(
	int length,
	Random random = null
)

Parameters

length  Int32
The length of the permutation.
random  Random  (Optional)
Optional. The random number generator.

Return Value

Permutation
A random permutation of length length.

Exceptions

ArgumentOutOfRangeException

length is less than zero.

See Also