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