--- title: "random(a,b,c)" slug: "math-random-with-range" updated: 2026-08-13T13:16:56Z published: 2026-08-13T13:16:56Z canonical: "docs.lobstersoftware.com/math-random-with-range" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.lobstersoftware.com/llms.txt > Use this file to discover all available pages before exploring further. # random(a,b,c) This function returns a random number (double or integer, depending on **c**) between the lower bound **a** (inclusive) and upper bound **b** (exclusive). ## Parameters | Parameter | Description | | --- | --- | | a | Lower bound (inclusive) | | b | Upper bound (exclusive) | | c | (optional) *true* if an integer value should be returned instead of a double value. Default: *false* | ## Examples | Parameter a | Parameter b | Parameter c | Result | | --- | --- | --- | --- | | 0 | 10 | | Double value between *0* (inclusive) and *10* (exclusive). | | 0 | 10 | false | Double value between *0* (inclusive) and *10* (exclusive). | | 0 | 10 | true | Integer value between *0* (inclusive) and *10* (exclusive). |