FastRandomNextInt32 Method

Returns a non-negative random 32-bit integer that is less than Int32.MaxValue.

Definition

Namespace: KGySoft.CoreLibraries
Assembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 10.0.0
C#
public int NextInt32()

Return Value

Int32
A 32-bit signed integer that is greater than or equal to 0 and less than Int32.MaxValue.

Remarks

  Caution

Starting with version 6.0.0 the behavior of this method has been changed to be conform with the behavior of the Random.NextInt64 method introduced in .NET 6.0 so it returns the same range as the Next method. Use the SampleInt32 method to obtain any Int32 value.

See Also