import java.util.*;
public class Main {
	static Scanner sc = new Scanner(System.in);
	static int a, b;

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO ツ篠ゥツ督ョツ青カツ青ャツつウツづェツつスツδソツッツドツ・ツスツタツブ
		while(read()){
			slove();
		}
	}
	static boolean read(){
		if(!sc.hasNext())
			return false;
		a = sc.nextInt(); b = sc.nextInt();
		
		return true;
	}
	static void slove(){
		int ans = Integer.toString(a+b).length();
		System.out.println(ans);
	}
} import java.util.*; util.* java public class Main {
	static Scanner sc = new Scanner(System.in);
	static int a, b;

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO ツ篠ゥツ督ョツ青カツ青ャツつウツづェツつスツδソツッツドツ・ツスツタツブ
		while(read()){
			slove();
		}
	}
	static boolean read(){
		if(!sc.hasNext())
			return false;
		a = sc.nextInt(); b = sc.nextInt();
		
		return true;
	}
	static void slove(){
		int ans = Integer.toString(a+b).length();
		System.out.println(ans);
	}
} Main static Scanner sc = new Scanner(System.in); sc new Scanner(System.in) static int a a b; b /**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO ツ篠ゥツ督ョツ青カツ青ャツつウツづェツつスツδソツッツドツ・ツスツタツブ
		while(read()){
			slove();
		}
	} main {
		// TODO ツ篠ゥツ督ョツ青カツ青ャツつウツづェツつスツδソツッツドツ・ツスツタツブ
		while(read()){
			slove();
		}
	} while(read()){
			slove();
		} read() read {
			slove();
		} slove() slove String[] args args static boolean read(){
		if(!sc.hasNext())
			return false;
		a = sc.nextInt(); b = sc.nextInt();
		
		return true;
	} read {
		if(!sc.hasNext())
			return false;
		a = sc.nextInt(); b = sc.nextInt();
		
		return true;
	} if(!sc.hasNext())
			return false; !sc.hasNext() sc.hasNext() sc.hasNext sc return false; false a = sc.nextInt() a sc.nextInt() sc.nextInt sc b = sc.nextInt() b sc.nextInt() sc.nextInt sc return true; true static void slove(){
		int ans = Integer.toString(a+b).length();
		System.out.println(ans);
	} slove {
		int ans = Integer.toString(a+b).length();
		System.out.println(ans);
	} int ans = Integer.toString(a+b).length(); ans Integer.toString(a+b).length() Integer.toString(a+b).length Integer.toString(a+b) Integer.toString Integer a+b a b System.out.println(ans) System.out.println System.out System System.out ans public class Main {
	static Scanner sc = new Scanner(System.in);
	static int a, b;

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO ツ篠ゥツ督ョツ青カツ青ャツつウツづェツつスツδソツッツドツ・ツスツタツブ
		while(read()){
			slove();
		}
	}
	static boolean read(){
		if(!sc.hasNext())
			return false;
		a = sc.nextInt(); b = sc.nextInt();
		
		return true;
	}
	static void slove(){
		int ans = Integer.toString(a+b).length();
		System.out.println(ans);
	}
} public class Main {
	static Scanner sc = new Scanner(System.in);
	static int a, b;

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO ツ篠ゥツ督ョツ青カツ青ャツつウツづェツつスツδソツッツドツ・ツスツタツブ
		while(read()){
			slove();
		}
	}
	static boolean read(){
		if(!sc.hasNext())
			return false;
		a = sc.nextInt(); b = sc.nextInt();
		
		return true;
	}
	static void slove(){
		int ans = Integer.toString(a+b).length();
		System.out.println(ans);
	}
} Main
import java.util.*;
public class Main {
	static Scanner sc = new Scanner(System.in);
	static int a, b;

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO ツ篠ゥツ督ョツ青カツ青ャツつウツづェツつスツδソツッツドツ・ツスツタツブ
		while(read()){
			slove();
		}
	}
	static boolean read(){
		if(!sc.hasNext())
			return false;
		a = sc.nextInt(); b = sc.nextInt();
		
		return true;
	}
	static void slove(){
		int ans = Integer.toString(a+b).length();
		System.out.println(ans);
	}
}