import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		final int lowerLimit = 0;
		final int upperLimit = 1000000;
		int num1, num2;
		Scanner scan = new Scanner(System.in);
		
		while(scan.hasNext()) {
			num1 = scan.nextInt();
			num2 = scan.nextInt();
			
			if((num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit)) {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} else {
				continue;
			}
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		final int lowerLimit = 0;
		final int upperLimit = 1000000;
		int num1, num2;
		Scanner scan = new Scanner(System.in);
		
		while(scan.hasNext()) {
			num1 = scan.nextInt();
			num2 = scan.nextInt();
			
			if((num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit)) {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} else {
				continue;
			}
		}
	}
} Main public static void main(String[] args) {
		final int lowerLimit = 0;
		final int upperLimit = 1000000;
		int num1, num2;
		Scanner scan = new Scanner(System.in);
		
		while(scan.hasNext()) {
			num1 = scan.nextInt();
			num2 = scan.nextInt();
			
			if((num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit)) {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} else {
				continue;
			}
		}
	} main {
		final int lowerLimit = 0;
		final int upperLimit = 1000000;
		int num1, num2;
		Scanner scan = new Scanner(System.in);
		
		while(scan.hasNext()) {
			num1 = scan.nextInt();
			num2 = scan.nextInt();
			
			if((num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit)) {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} else {
				continue;
			}
		}
	} final int lowerLimit = 0; lowerLimit 0 final int upperLimit = 1000000; upperLimit 1000000 int num1 num1 num2; num2 Scanner scan = new Scanner(System.in); scan new Scanner(System.in) while(scan.hasNext()) {
			num1 = scan.nextInt();
			num2 = scan.nextInt();
			
			if((num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit)) {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} else {
				continue;
			}
		} scan.hasNext() scan.hasNext scan {
			num1 = scan.nextInt();
			num2 = scan.nextInt();
			
			if((num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit)) {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} else {
				continue;
			}
		} num1 = scan.nextInt() num1 scan.nextInt() scan.nextInt scan num2 = scan.nextInt() num2 scan.nextInt() scan.nextInt scan if((num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit)) {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} else {
				continue;
			} (num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit) (num1 >= lowerLimit && num1 <= upperLimit) num1 >= lowerLimit num1 lowerLimit num1 <= upperLimit num1 upperLimit (num2 >= lowerLimit && num2 <= upperLimit) num2 >= lowerLimit num2 lowerLimit num2 <= upperLimit num2 upperLimit {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} System.out.println((int)Math.log10(num1 + num2) + 1) System.out.println System.out System System.out (int)Math.log10(num1 + num2) + 1 (int)Math.log10(num1 + num2) Math.log10 Math num1 + num2 num1 num2 1 {
				continue;
			} continue; String[] args args public class Main {
	public static void main(String[] args) {
		final int lowerLimit = 0;
		final int upperLimit = 1000000;
		int num1, num2;
		Scanner scan = new Scanner(System.in);
		
		while(scan.hasNext()) {
			num1 = scan.nextInt();
			num2 = scan.nextInt();
			
			if((num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit)) {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} else {
				continue;
			}
		}
	}
} public class Main {
	public static void main(String[] args) {
		final int lowerLimit = 0;
		final int upperLimit = 1000000;
		int num1, num2;
		Scanner scan = new Scanner(System.in);
		
		while(scan.hasNext()) {
			num1 = scan.nextInt();
			num2 = scan.nextInt();
			
			if((num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit)) {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} else {
				continue;
			}
		}
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		final int lowerLimit = 0;
		final int upperLimit = 1000000;
		int num1, num2;
		Scanner scan = new Scanner(System.in);
		
		while(scan.hasNext()) {
			num1 = scan.nextInt();
			num2 = scan.nextInt();
			
			if((num1 >= lowerLimit && num1 <= upperLimit)
				&& (num2 >= lowerLimit && num2 <= upperLimit)) {
				System.out.println((int)Math.log10(num1 + num2) + 1);		
			} else {
				continue;
			}
		}
	}
}