= $count)) { throw new Exception($parameterName.' is an invalid index'); } } public static function argumentInRangeInclusive(float $value, float $min, float $max, string $parameterName): void { if (($value < $min) || ($value > $max)) { throw new Exception($parameterName.' is not in the valid range ['.$min.', '.$max.']'); } } }