RandomExtensionsSampleInt32 Method
Returns a random
Int32 that can have any value.
Namespace: KGySoft.CoreLibrariesAssembly: KGySoft.CoreLibraries (in KGySoft.CoreLibraries.dll) Version: 10.0.0
public static int SampleInt32(
this Random random
)
<ExtensionAttribute>
Public Shared Function SampleInt32 (
random As Random
) As Integer
public:
[ExtensionAttribute]
static int SampleInt32(
Random^ random
)
[<ExtensionAttribute>]
static member SampleInt32 :
random : Random -> int
- random Random
- The Random instance to use.
Int32A 32-bit signed integer that is greater than or equal to
Int32.MinValue and less than or equal to
Int32.MaxValue.In Visual Basic and C#, you can call this method as an instance method on any object of type
Random. 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).
Similarly to the
Random.Next() method this one returns an
Int32 value; however, the result can be negative and
the maximum possible value can be
Int32.MaxValue.