src/Money.php
public static function min(Money $money, Money ...$monies) : Money
    {
        $min = $money;

        foreach ($monies as $money) {
            if ($money->isLessThan($min)) {
                $min = $money;
            }
        }

        return $min;
    }
public static function min(Money $money, Money ...$monies) : Money
    {
        $min = $money;

        foreach ($monies as $money) {
            if ($money->isLessThan($min)) {
                $min = $money;
            }
        }

        return $min;
    }
public static function min ( Money $ money , Money ... $ monies ) : Money { $ min = $ money ; foreach ( $ monies as $ money ) { if ( $ money -> isLessThan ( $ min ) ) { $ min = $ money ; } } return $ min ; }
Returns the minimum of the given monies.

If several monies are equal to the minimum value, the first one is returned.

@param Money    $money  The first money.
@param Money ...$monies The subsequent monies.

@return Money

@throws MoneyMismatchException If all the monies are not in the same currency.
Returns the minimum of the given monies .