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

PHP mt_getrandmax() Function

PHP mt_getrandmax() Function

PHP Math Reference Manual PHP Math Reference Manual

Example

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

Run Example »


Definition and Usage

The mt_getrandmax() function returns the largest possible random value produced by calling mt_rand() function.


Syntax

mt_getrandmax();

Technical Details

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

PHP Math Reference Manual PHP Math Reference Manual