mt_rand():

echo mt_rand(10,100); // Output is 32 
Syntax
int mt_rand ( int $min, int $max)
ParameterDESCRIPTION
$minOptional : Minimum range of random number to be generated.
$maxOptional : Maximum range of random number to be generated.

Output is a random value.

This function uses Mersenne Twister Random Number Generator.

Example 1

echo mt_rand();
Out put is ( will chage )
2147483647

Math Functions getrandmax(): Getting highest random number max() function
Subscribe to our YouTube Channel here


Subscribe

* indicates required
Subscribe to plus2net

    plus2net.com







    Post your comments , suggestion , error , requirements etc here





    PHP video Tutorials
    We use cookies to improve your browsing experience. . Learn more
    HTML MySQL PHP JavaScript ASP Photoshop Articles FORUM . Contact us
    ©2000-2024 plus2net.com All rights reserved worldwide Privacy Policy Disclaimer