Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

PHP getrandmax() Function

PHP getrandmax() Function

PHP Math Reference Manual PHP Math Reference Manual

Example

Return the largest possible value of a random number produced by calling rand():

Run Example »


Definition and Usage

The getrandmax() function returns the largest possible random value produced by calling the rand() function.


Syntax

getrandmax();

Technical Details

Return Value: The largest possible random value produced by calling the rand() function.
Return Type: Integer
PHP Version: 4+

PHP Math Reference Manual PHP Math Reference Manual