import java.io.*;

class Main{
	public static void main(String args[]){
		BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
		while(true){
			String input="";
			try{
				input = reader.readLine();
			}catch(IOException e){
				
			}
			if(input==null){
				break;
			}
			
			String array[] = input.split(" ");
			int a = Integer.parseInt(array[0]);
			int b = Integer.parseInt(array[1]);
			int num = a+b;
			int cou=0;
			while(num>0){
				num/=10;
				cou++;	
			}
			System.out.println(cou);
		}
	}
} import java.io.*; io.* java class Main{
	public static void main(String args[]){
		BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
		while(true){
			String input="";
			try{
				input = reader.readLine();
			}catch(IOException e){
				
			}
			if(input==null){
				break;
			}
			
			String array[] = input.split(" ");
			int a = Integer.parseInt(array[0]);
			int b = Integer.parseInt(array[1]);
			int num = a+b;
			int cou=0;
			while(num>0){
				num/=10;
				cou++;	
			}
			System.out.println(cou);
		}
	}
} Main public static void main(String args[]){
		BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
		while(true){
			String input="";
			try{
				input = reader.readLine();
			}catch(IOException e){
				
			}
			if(input==null){
				break;
			}
			
			String array[] = input.split(" ");
			int a = Integer.parseInt(array[0]);
			int b = Integer.parseInt(array[1]);
			int num = a+b;
			int cou=0;
			while(num>0){
				num/=10;
				cou++;	
			}
			System.out.println(cou);
		}
	} main {
		BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
		while(true){
			String input="";
			try{
				input = reader.readLine();
			}catch(IOException e){
				
			}
			if(input==null){
				break;
			}
			
			String array[] = input.split(" ");
			int a = Integer.parseInt(array[0]);
			int b = Integer.parseInt(array[1]);
			int num = a+b;
			int cou=0;
			while(num>0){
				num/=10;
				cou++;	
			}
			System.out.println(cou);
		}
	} BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); reader new BufferedReader(new InputStreamReader(System.in)) while(true){
			String input="";
			try{
				input = reader.readLine();
			}catch(IOException e){
				
			}
			if(input==null){
				break;
			}
			
			String array[] = input.split(" ");
			int a = Integer.parseInt(array[0]);
			int b = Integer.parseInt(array[1]);
			int num = a+b;
			int cou=0;
			while(num>0){
				num/=10;
				cou++;	
			}
			System.out.println(cou);
		} true {
			String input="";
			try{
				input = reader.readLine();
			}catch(IOException e){
				
			}
			if(input==null){
				break;
			}
			
			String array[] = input.split(" ");
			int a = Integer.parseInt(array[0]);
			int b = Integer.parseInt(array[1]);
			int num = a+b;
			int cou=0;
			while(num>0){
				num/=10;
				cou++;	
			}
			System.out.println(cou);
		} String input=""; input "" try{
				input = reader.readLine();
			}catch(IOException e){
				
			} catch(IOException e){
				
			} IOException e {
				
			} {
				input = reader.readLine();
			} input = reader.readLine() input reader.readLine() reader.readLine reader if(input==null){
				break;
			} input==null input null {
				break;
			} break; String array[] = input.split(" "); array input.split(" ") input.split input " " int a = Integer.parseInt(array[0]); a Integer.parseInt(array[0]) Integer.parseInt Integer array[0] array 0 int b = Integer.parseInt(array[1]); b Integer.parseInt(array[1]) Integer.parseInt Integer array[1] array 1 int num = a+b; num a+b a b int cou=0; cou 0 while(num>0){
				num/=10;
				cou++;	
			} num>0 num 0 {
				num/=10;
				cou++;	
			} num/=10 num 10 cou++ cou System.out.println(cou) System.out.println System.out System System.out cou String args[] args
import java.io.*;

class Main{
	public static void main(String args[]){
		BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
		while(true){
			String input="";
			try{
				input = reader.readLine();
			}catch(IOException e){
				
			}
			if(input==null){
				break;
			}
			
			String array[] = input.split(" ");
			int a = Integer.parseInt(array[0]);
			int b = Integer.parseInt(array[1]);
			int num = a+b;
			int cou=0;
			while(num>0){
				num/=10;
				cou++;	
			}
			System.out.println(cou);
		}
	}
}