import java.util.List;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Scanner;

public class Main {
	public static void main(String[]args){
		DigitNum();
	}
	
	public static void DigitNum(){
			Scanner scan = new Scanner(System.in);
			while(scan.hasNext()){
			int sum = scan.nextInt()+scan.nextInt();
			System.out.println(String.valueOf(sum).length());
		}
	}
} import java.util.List; List java.util import java.util.ArrayList; ArrayList java.util import java.util.Collections; Collections java.util import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[]args){
		DigitNum();
	}
	
	public static void DigitNum(){
			Scanner scan = new Scanner(System.in);
			while(scan.hasNext()){
			int sum = scan.nextInt()+scan.nextInt();
			System.out.println(String.valueOf(sum).length());
		}
	}
} Main public static void main(String[]args){
		DigitNum();
	} main {
		DigitNum();
	} DigitNum() DigitNum String[]args args public static void DigitNum(){
			Scanner scan = new Scanner(System.in);
			while(scan.hasNext()){
			int sum = scan.nextInt()+scan.nextInt();
			System.out.println(String.valueOf(sum).length());
		}
	} DigitNum {
			Scanner scan = new Scanner(System.in);
			while(scan.hasNext()){
			int sum = scan.nextInt()+scan.nextInt();
			System.out.println(String.valueOf(sum).length());
		}
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) while(scan.hasNext()){
			int sum = scan.nextInt()+scan.nextInt();
			System.out.println(String.valueOf(sum).length());
		} scan.hasNext() scan.hasNext scan {
			int sum = scan.nextInt()+scan.nextInt();
			System.out.println(String.valueOf(sum).length());
		} int sum = scan.nextInt()+scan.nextInt(); sum scan.nextInt()+scan.nextInt() scan.nextInt() scan.nextInt scan scan.nextInt() scan.nextInt scan 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 public class Main {
	public static void main(String[]args){
		DigitNum();
	}
	
	public static void DigitNum(){
			Scanner scan = new Scanner(System.in);
			while(scan.hasNext()){
			int sum = scan.nextInt()+scan.nextInt();
			System.out.println(String.valueOf(sum).length());
		}
	}
} public class Main {
	public static void main(String[]args){
		DigitNum();
	}
	
	public static void DigitNum(){
			Scanner scan = new Scanner(System.in);
			while(scan.hasNext()){
			int sum = scan.nextInt()+scan.nextInt();
			System.out.println(String.valueOf(sum).length());
		}
	}
} Main
import java.util.List;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Scanner;

public class Main {
	public static void main(String[]args){
		DigitNum();
	}
	
	public static void DigitNum(){
			Scanner scan = new Scanner(System.in);
			while(scan.hasNext()){
			int sum = scan.nextInt()+scan.nextInt();
			System.out.println(String.valueOf(sum).length());
		}
	}
}