Random\Randomizer::getInt

(PHP 8 >= 8.2.0)

Random\Randomizer::getIntGet a uniformly selected integer

说明

public Random\Randomizer::getInt(int $min, int $max): int

警告

本函数还未编写文档,仅有参数列表。

参数

min

The lowest value to be returned; must be PHP_INT_MIN or greater.

max

The highest value to be returned; must be PHP_INT_MAX or less.

返回值

A uniformly selected integer from the closed interval [min, max]. Both min and max are possible return values.

错误/异常

范例

示例 #1 Random\Randomizer::getInt() example

<?php

/* ... */

?>

以上例程的输出类似于:

...

参见