e2cfad6b创建于 2023年10月6日历史提交
class Solution {
    public int integerBreak(int n) {
        if (n < 4) return n - 1;

        int res = 1;

        while (n > 4) {
            n -= 3;
            res *= 3;
        } 

        res *= n;
        return res;
    }
}