function fusc(n)
    n = math.floor(n)
    if n == 0 or n == 1 then
        return n
    elseif n % 2 == 0 then
        return fusc(n / 2)
    else
        return fusc((n - 1) / 2) + fusc((n + 1) / 2)
    end
end

function numLen(n)
    local sum = 1
    while n > 9 do
        n = math.floor(n / 10)
        sum = sum + 1
    end
    return sum
end

function printLargeFuscs(limit)
    print("Printing all largest Fusc numbers up to " .. limit)
    print("Index