Supported Versions: PHP 4, PHP 5, PHP 7, PHP 8
Round fractions up
<?php ceil(int|float $num): float
<?php             if (self::PERIOD_LIMIT === $i) {

                $now = new \DateTimeImmutable('now', new \DateTimeZone('UTC'));

                $dates[] = sprintf('%s more', ($end = $p->getEndDate())

                    ? ceil(($end->format('U.u') - $d->format('U.u')) / ((int) $now->add($p->getDateInterval())->format('U.u') - (int) $now->format('U.u')))

                    : $p->recurrences - $i

                );

                break;