import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Created by mixnector on 2017/03/04.
 */
public class Main {
    static Scanner in;
    static PrintWriter out;
    static String INPUT = "";

    public static void main(String[] args) throws Exception
    {
        in = INPUT.isEmpty() ? new Scanner(System.in) : new Scanner(INPUT);
        out = new PrintWriter(System.out);
        long N = nl();

        int halfN = (int)Math.sqrt(N);

        int min = 10;
        int A;
        long B;
        for(A = 1; A <= halfN; A++)
        {
            if(N % A == 0)
            {
                B = N / A;
                int F = (int)Math.log10(B) + 1;
                if(min > F)
                    min = F;
            }
        }

        out.println(min);
        out.flush();
    }

    static long nl() {
        return Long.parseLong(in.next());
    }
}
/tmp/hf-datasets-cache/medium/datasets/42704881117311-config-parquet-and-info-qiankunmu-Project_CodeNet-896c9d36/hub/datasets--qiankunmu--Project_CodeNet_Python800_and_Java250/snapshots/c899fde44a77ba1cc14973ed3de064e4ff3aadc7/Project_CodeNet_Java250.tar.gz