@@ -15,7 +15,7 @@ discard block |
||
15 | 15 | * |
16 | 16 | * @return float|int Random number |
17 | 17 | */ |
18 | - public static function rand(): int|float |
|
18 | + public static function rand(): int | float |
|
19 | 19 | { |
20 | 20 | return mt_rand(0, 10000000) / 10000000; |
21 | 21 | } |
@@ -32,7 +32,7 @@ discard block |
||
32 | 32 | * If an array of numbers is passed as an argument, then the returned result will also be an array |
33 | 33 | * with the same dimensions |
34 | 34 | */ |
35 | - public static function randBetween(mixed $min, mixed $max): array|string|int |
|
35 | + public static function randBetween(mixed $min, mixed $max): array | string | int |
|
36 | 36 | { |
37 | 37 | if (is_array($min) || is_array($max)) { |
38 | 38 | return self::evaluateArrayArguments([self::class, __FUNCTION__], $min, $max); |
@@ -67,7 +67,7 @@ discard block |
||
67 | 67 | * |
68 | 68 | * @return array|string The resulting array, or a string containing an error |
69 | 69 | */ |
70 | - public static function randArray(mixed $rows = 1, mixed $columns = 1, mixed $min = 0, mixed $max = 1, bool $wholeNumber = false): string|array |
|
70 | + public static function randArray(mixed $rows = 1, mixed $columns = 1, mixed $min = 0, mixed $max = 1, bool $wholeNumber = false): string | array |
|
71 | 71 | { |
72 | 72 | try { |
73 | 73 | $rows = (int) Helpers::validateNumericNullSubstitution($rows, 1); |
@@ -86,7 +86,7 @@ discard block |
||
86 | 86 | |
87 | 87 | return array_chunk( |
88 | 88 | array_map( |
89 | - fn (): int|float => $wholeNumber |
|
89 | + fn (): int | float => $wholeNumber |
|
90 | 90 | ? mt_rand((int) $min, (int) $max) |
91 | 91 | : (mt_rand() / mt_getrandmax()) * ($max - $min) + $min, |
92 | 92 | array_fill(0, $rows * $columns, $min) |