import java.util.Scanner;

public class Main{
    private static Scanner sc=new Scanner(System.in);
    private static long n=sc.nextLong();
    public static void main(String[] args){
        int sq=(int)(Math.sqrt(n));
        int ans=0;
        for(int i=sq;i>=1;i--){
            if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            }
        }
        System.out.println(ans);
    }
} import java.util.Scanner; Scanner java.util public class Main{
    private static Scanner sc=new Scanner(System.in);
    private static long n=sc.nextLong();
    public static void main(String[] args){
        int sq=(int)(Math.sqrt(n));
        int ans=0;
        for(int i=sq;i>=1;i--){
            if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            }
        }
        System.out.println(ans);
    }
} Main private static Scanner sc=new Scanner(System.in); sc new Scanner(System.in) private static long n=sc.nextLong(); n sc.nextLong() sc.nextLong sc public static void main(String[] args){
        int sq=(int)(Math.sqrt(n));
        int ans=0;
        for(int i=sq;i>=1;i--){
            if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            }
        }
        System.out.println(ans);
    } main {
        int sq=(int)(Math.sqrt(n));
        int ans=0;
        for(int i=sq;i>=1;i--){
            if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            }
        }
        System.out.println(ans);
    } int sq=(int)(Math.sqrt(n)); sq (int)(Math.sqrt(n)) Math.sqrt Math n int ans=0; ans 0 for(int i=sq;i>=1;i--){
            if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            }
        } int i=sq; int i=sq; i sq i>=1 i 1 i-- i-- i {
            if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            }
        } {
            if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            }
        } if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            } n%i==0 n%i n i 0 {
                ans=String.valueOf(n/i).length();
                i=0;
            } ans=String.valueOf(n/i).length() ans String.valueOf(n/i).length() String.valueOf(n/i).length String.valueOf(n/i) String.valueOf String n/i n i i=0 i 0 System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main{
    private static Scanner sc=new Scanner(System.in);
    private static long n=sc.nextLong();
    public static void main(String[] args){
        int sq=(int)(Math.sqrt(n));
        int ans=0;
        for(int i=sq;i>=1;i--){
            if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            }
        }
        System.out.println(ans);
    }
} public class Main{
    private static Scanner sc=new Scanner(System.in);
    private static long n=sc.nextLong();
    public static void main(String[] args){
        int sq=(int)(Math.sqrt(n));
        int ans=0;
        for(int i=sq;i>=1;i--){
            if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            }
        }
        System.out.println(ans);
    }
} Main
import java.util.Scanner;

public class Main{
    private static Scanner sc=new Scanner(System.in);
    private static long n=sc.nextLong();
    public static void main(String[] args){
        int sq=(int)(Math.sqrt(n));
        int ans=0;
        for(int i=sq;i>=1;i--){
            if(n%i==0){
                ans=String.valueOf(n/i).length();
                i=0;
            }
        }
        System.out.println(ans);
    }
}