getrandmax
(PHP 4, PHP 5)
getrandmax — Show largest possible random value
Description
int getrandmax
( void
)
Returns the maximum value that can be returned by a call to rand().
Return Values
The largest possible random value returned by rand()
See Also
- rand() - Generate a random integer
- srand() - Seed the random number generator
- mt_getrandmax() - Show largest possible random value
- PHP Руководство
- Функции по категориям
- Индекс функций
- Справочник функций
- Математические расширения
- Математические функции
- abs
- acos
- acosh
- asin
- asinh
- atan2
- atan
- atanh
- base_convert
- bindec
- ceil
- cos
- cosh
- decbin
- dechex
- decoct
- deg2rad
- exp
- expm1
- floor
- fmod
- getrandmax
- hexdec
- hypot
- intdiv
- is_finite
- is_infinite
- is_nan
- lcg_value
- log10
- log1p
- log
- max
- min
- mt_getrandmax
- mt_rand
- mt_srand
- octdec
- pi
- pow
- rad2deg
- rand
- round
- sin
- sinh
- sqrt
- srand
- tan
- tanh
Коментарии
On a stock installation as of version 7.4.33 / 8.1.12, this function seems to return 2147483647 (maximum 32-bit integer).