import java.io.*;

public class Main{
  public static void main(String[] args) throws Exception{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String line=null;
        while((line=br.readLine())!=null){
        	String[] array=line.split(" ");
        	int sum=Integer.parseInt(array[0])+Integer.parseInt(array[1]);
        	System.out.println(String.valueOf(sum).length());
        }
    }
} import java.io.*; io.* java public class Main{
  public static void main(String[] args) throws Exception{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String line=null;
        while((line=br.readLine())!=null){
        	String[] array=line.split(" ");
        	int sum=Integer.parseInt(array[0])+Integer.parseInt(array[1]);
        	System.out.println(String.valueOf(sum).length());
        }
    }
} Main public static void main(String[] args) throws Exception{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String line=null;
        while((line=br.readLine())!=null){
        	String[] array=line.split(" ");
        	int sum=Integer.parseInt(array[0])+Integer.parseInt(array[1]);
        	System.out.println(String.valueOf(sum).length());
        }
    } main {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String line=null;
        while((line=br.readLine())!=null){
        	String[] array=line.split(" ");
        	int sum=Integer.parseInt(array[0])+Integer.parseInt(array[1]);
        	System.out.println(String.valueOf(sum).length());
        }
    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) String line=null; line null while((line=br.readLine())!=null){
        	String[] array=line.split(" ");
        	int sum=Integer.parseInt(array[0])+Integer.parseInt(array[1]);
        	System.out.println(String.valueOf(sum).length());
        } (line=br.readLine())!=null (line=br.readLine()) line br.readLine() br.readLine br null {
        	String[] array=line.split(" ");
        	int sum=Integer.parseInt(array[0])+Integer.parseInt(array[1]);
        	System.out.println(String.valueOf(sum).length());
        } String[] array=line.split(" "); array line.split(" ") line.split line " " int sum=Integer.parseInt(array[0])+Integer.parseInt(array[1]); sum Integer.parseInt(array[0])+Integer.parseInt(array[1]) Integer.parseInt(array[0]) Integer.parseInt Integer array[0] array 0 Integer.parseInt(array[1]) Integer.parseInt Integer array[1] array 1 System.out.println(String.valueOf(sum).length()) System.out.println System.out System System.out String.valueOf(sum).length() String.valueOf(sum).length String.valueOf(sum) String.valueOf String sum String[] args args public class Main{
  public static void main(String[] args) throws Exception{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String line=null;
        while((line=br.readLine())!=null){
        	String[] array=line.split(" ");
        	int sum=Integer.parseInt(array[0])+Integer.parseInt(array[1]);
        	System.out.println(String.valueOf(sum).length());
        }
    }
} public class Main{
  public static void main(String[] args) throws Exception{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String line=null;
        while((line=br.readLine())!=null){
        	String[] array=line.split(" ");
        	int sum=Integer.parseInt(array[0])+Integer.parseInt(array[1]);
        	System.out.println(String.valueOf(sum).length());
        }
    }
} Main
import java.io.*;

public class Main{
  public static void main(String[] args) throws Exception{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String line=null;
        while((line=br.readLine())!=null){
        	String[] array=line.split(" ");
        	int sum=Integer.parseInt(array[0])+Integer.parseInt(array[1]);
        	System.out.println(String.valueOf(sum).length());
        }
    }
}