import java.util.*;

class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        long N = sc.nextLong();
        long min = 100;

        for (long i=1; i<(long) Math.sqrt(N)+1; i++) {
            if (N % i != 0) { 
                continue;
            }
            long m = i > (N / i) ? i : (N / i);
            long a = (long) Math.log10(m) + 1;
            min = min < a ? min : a;
        }

        System.out.println(min);
    }
}
 import java.util.*; util.* java class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        long N = sc.nextLong();
        long min = 100;

        for (long i=1; i<(long) Math.sqrt(N)+1; i++) {
            if (N % i != 0) { 
                continue;
            }
            long m = i > (N / i) ? i : (N / i);
            long a = (long) Math.log10(m) + 1;
            min = min < a ? min : a;
        }

        System.out.println(min);
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        long N = sc.nextLong();
        long min = 100;

        for (long i=1; i<(long) Math.sqrt(N)+1; i++) {
            if (N % i != 0) { 
                continue;
            }
            long m = i > (N / i) ? i : (N / i);
            long a = (long) Math.log10(m) + 1;
            min = min < a ? min : a;
        }

        System.out.println(min);
    } main {
        Scanner sc = new Scanner(System.in);

        long N = sc.nextLong();
        long min = 100;

        for (long i=1; i<(long) Math.sqrt(N)+1; i++) {
            if (N % i != 0) { 
                continue;
            }
            long m = i > (N / i) ? i : (N / i);
            long a = (long) Math.log10(m) + 1;
            min = min < a ? min : a;
        }

        System.out.println(min);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) long N = sc.nextLong(); N sc.nextLong() sc.nextLong sc long min = 100; min 100 for (long i=1; i<(long) Math.sqrt(N)+1; i++) {
            if (N % i != 0) { 
                continue;
            }
            long m = i > (N / i) ? i : (N / i);
            long a = (long) Math.log10(m) + 1;
            min = min < a ? min : a;
        } long i=1; long i=1; i 1 i<(long) Math.sqrt(N)+1 i (long) Math.sqrt(N)+1 (long) Math.sqrt(N) Math.sqrt Math N 1 i++ i++ i {
            if (N % i != 0) { 
                continue;
            }
            long m = i > (N / i) ? i : (N / i);
            long a = (long) Math.log10(m) + 1;
            min = min < a ? min : a;
        } {
            if (N % i != 0) { 
                continue;
            }
            long m = i > (N / i) ? i : (N / i);
            long a = (long) Math.log10(m) + 1;
            min = min < a ? min : a;
        } if (N % i != 0) { 
                continue;
            } N % i != 0 N % i N i 0 { 
                continue;
            } continue; long m = i > (N / i) ? i : (N / i); m i > (N / i) ? i : (N / i) i > (N / i) i (N / i) N i i (N / i) N i long a = (long) Math.log10(m) + 1; a (long) Math.log10(m) + 1 (long) Math.log10(m) Math.log10 Math m 1 min = min < a ? min : a min min < a ? min : a min < a min a min a System.out.println(min) System.out.println System.out System System.out min String[] args args
import java.util.*;

class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        long N = sc.nextLong();
        long min = 100;

        for (long i=1; i<(long) Math.sqrt(N)+1; i++) {
            if (N % i != 0) { 
                continue;
            }
            long m = i > (N / i) ? i : (N / i);
            long a = (long) Math.log10(m) + 1;
            min = min < a ? min : a;
        }

        System.out.println(min);
    }
}

