Latest web development tutorials

PHP getrandmax () function

PHP Math Reference PHP Math Reference

Examples

Returns the maximum possible value of the random number by calling the rand () function displays:

<?php
echo(getrandmax());
?>

Running instance »

Definition and Usage

The getrandmax () function returns by calling the rand () the maximum possible value of the random number function display.


grammar

getrandmax();

technical details

return value: () The maximum possible value by calling the rand function to display random number.
Return type: Integer
PHP version: 4+


PHP Math Reference PHP Math Reference