random

Generates a random number between 0 and 1.

Category

Maths

Function syntax

random(<parameters>)

Signature and returned type

random()

Returns a decimal.

Example

#{MarltonReservation.statistics.successRatio, defaultValue : random() * 100}

Explanation: if the success ratio has no value/is null, the default value will be applied and will be a random figure between 0 and 1 * 100 (meaning 0 to 100).

On this page

Adobe Summit Banner

A virtual event April 27-28.

Expand your skills and get inspired.

Register for free
Adobe Summit Banner

A virtual event April 27-28.

Expand your skills and get inspired.

Register for free
Adobe Maker Awards Banner

Time to shine!

Apply now for the 2021 Adobe Experience Maker Awards.

Apply now
Adobe Maker Awards Banner

Time to shine!

Apply now for the 2021 Adobe Experience Maker Awards.

Apply now