Answers for "rand between php"

PHP
7

php random number

// $min and $max are optional
rand($min,$max);
Posted by: Guest on April-14-2020
0

php rand vs mt_rand

// Since PHP7.1 rand() has become an alias of mt_rand()
// mt_rand() was supposed to be faster and more random than rand() in older PHP Versions
// That means you can use rand() instead of mt_rand() on newer Versions
<?php
  rand(1, 100);		// will generate a random number between 1 and 100
?>
Posted by: Guest on January-20-2021
1

php random number

rand();
Posted by: Guest on March-27-2020

Browse Popular Code Answers by Language