PHP code example of g105b / drng
1. Go to this page and download the library: Download g105b/drng library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
g105b / drng example snippets
use g105b\drng\Random;
use g105b\drng\StringSeed;
$rand = new Random(
new StringSeed("i like cats")
);
echo "Random sequence: ";
for($i = 0; $i < 10; $i++) {
if($i > 0) {
echo ", ";
}
echo $rand->getInt(1, 10);
}