ballerina/random

Package Overview

This package provides functions related to random number generation. The random:createDecimal method generates a random decimal number between 0.0 and 1.0. The random:createIntInRange method generates a random number between the given start(inclusive) and end(exclusive) values.

For an example on the usage of the operations, see the Random Example.

Functions

[2]

createDecimal

Generates a random decimal number between 0.0 and 1.0.

createIntInRange

Generates a random number between the given start(inclusive) and end(exclusive) values.

Errors

[1]

Error

Represents Random module related errors.