import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		int a, b;
		String sum;
		Scanner scan = new Scanner(System.in);
		while (scan.hasNext()) {
			String num[] = scan.nextLine().split(" ", 0);
			a = Integer.parseInt(num[0]);
			b = Integer.parseInt(num[1]);
			sum = String.valueOf(a+b);
			System.out.println(sum.length());
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		int a, b;
		String sum;
		Scanner scan = new Scanner(System.in);
		while (scan.hasNext()) {
			String num[] = scan.nextLine().split(" ", 0);
			a = Integer.parseInt(num[0]);
			b = Integer.parseInt(num[1]);
			sum = String.valueOf(a+b);
			System.out.println(sum.length());
		}
	}
} Main public static void main(String[] args) {
		int a, b;
		String sum;
		Scanner scan = new Scanner(System.in);
		while (scan.hasNext()) {
			String num[] = scan.nextLine().split(" ", 0);
			a = Integer.parseInt(num[0]);
			b = Integer.parseInt(num[1]);
			sum = String.valueOf(a+b);
			System.out.println(sum.length());
		}
	} main {
		int a, b;
		String sum;
		Scanner scan = new Scanner(System.in);
		while (scan.hasNext()) {
			String num[] = scan.nextLine().split(" ", 0);
			a = Integer.parseInt(num[0]);
			b = Integer.parseInt(num[1]);
			sum = String.valueOf(a+b);
			System.out.println(sum.length());
		}
	} int a a b; b String sum; sum Scanner scan = new Scanner(System.in); scan new Scanner(System.in) while (scan.hasNext()) {
			String num[] = scan.nextLine().split(" ", 0);
			a = Integer.parseInt(num[0]);
			b = Integer.parseInt(num[1]);
			sum = String.valueOf(a+b);
			System.out.println(sum.length());
		} scan.hasNext() scan.hasNext scan {
			String num[] = scan.nextLine().split(" ", 0);
			a = Integer.parseInt(num[0]);
			b = Integer.parseInt(num[1]);
			sum = String.valueOf(a+b);
			System.out.println(sum.length());
		} String num[] = scan.nextLine().split(" ", 0); num scan.nextLine().split(" ", 0) scan.nextLine().split scan.nextLine() scan.nextLine scan " " 0 a = Integer.parseInt(num[0]) a Integer.parseInt(num[0]) Integer.parseInt Integer num[0] num 0 b = Integer.parseInt(num[1]) b Integer.parseInt(num[1]) Integer.parseInt Integer num[1] num 1 sum = String.valueOf(a+b) sum String.valueOf(a+b) String.valueOf String a+b a b System.out.println(sum.length()) System.out.println System.out System System.out sum.length() sum.length sum String[] args args public class Main {
	public static void main(String[] args) {
		int a, b;
		String sum;
		Scanner scan = new Scanner(System.in);
		while (scan.hasNext()) {
			String num[] = scan.nextLine().split(" ", 0);
			a = Integer.parseInt(num[0]);
			b = Integer.parseInt(num[1]);
			sum = String.valueOf(a+b);
			System.out.println(sum.length());
		}
	}
} public class Main {
	public static void main(String[] args) {
		int a, b;
		String sum;
		Scanner scan = new Scanner(System.in);
		while (scan.hasNext()) {
			String num[] = scan.nextLine().split(" ", 0);
			a = Integer.parseInt(num[0]);
			b = Integer.parseInt(num[1]);
			sum = String.valueOf(a+b);
			System.out.println(sum.length());
		}
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		int a, b;
		String sum;
		Scanner scan = new Scanner(System.in);
		while (scan.hasNext()) {
			String num[] = scan.nextLine().split(" ", 0);
			a = Integer.parseInt(num[0]);
			b = Integer.parseInt(num[1]);
			sum = String.valueOf(a+b);
			System.out.println(sum.length());
		}
	}
}