Sign in Join
FPDoc Onlineexperiment

RandomRange function

In unit Math

Return a random number in a range.

Declaration

pascal
function RandomRange(const aFrom: Integer; const aTo: Integer): Integer

Description

RandomRange returns a random value in the range AFrom to ATo. AFrom and ATo do not need to be in increasing order. The upper border is not included in the generated value, but the lower border is.

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.