N = int(eval(input()))



ans = 1<<60

for a in range(1, int(N**0.5)+1):

  if N%a==0:

    b = N//a

    max_len = max(len(str(a)), len(str(b)))

    ans = min(ans, max_len)

print(ans)  
def make_divisors(n):

    divisors = []

    for i in range(1, int(n**0.5)+1):

        if n % i == 0:

            divisors.append(i)

            if i != n // i:

                divisors.append(n//i)



    # divisors.sort()

    return divisors



N = int(eval(input()))

print((len(str(make_divisors(N)[-1]))))
N = int(eval(input()))
ans = 1 << 60
for a in range(1, int(N**0.5) + 1):
    if N % a == 0:
        b = N // a
        max_len = max(len(str(a)), len(str(b)))
        ans = min(ans, max_len)
print(ans)

def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5) + 1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n // i)
    # divisors.sort()
    return divisors


N = int(eval(input()))
print((len(str(make_divisors(N)[-1]))))

+def make_divisors(n): +    divisors = [] +    for i in range(1, int(n**0.5) + 1): +        if n % i == 0: +            divisors.append(i) +            if i != n // i: +                divisors.append(n // i) +    # divisors.sort() +    return divisors + + -ans = 1 << 60 -for a in range(1, int(N**0.5) + 1): -    if N % a == 0: -        b = N // a -        max_len = max(len(str(a)), len(str(b))) -        ans = min(ans, max_len) -print(ans) +print((len(str(make_divisors(N)[-1]))))