import java.util.Scanner;

public class Main {
	void run() {
		Scanner sc = new Scanner(System.in);

		while (sc.hasNext()) {
			int a = sc.nextInt();
			int b = sc.nextInt();

			int ans = 0;
			a += b;
			while (a > 0) {
				ans++;
				a /= 10;
			}
			System.out.println(ans);
		}
	}

	public static void main(String[] args) {
		new Main().run();
	}
} import java.util.Scanner; Scanner java.util public class Main {
	void run() {
		Scanner sc = new Scanner(System.in);

		while (sc.hasNext()) {
			int a = sc.nextInt();
			int b = sc.nextInt();

			int ans = 0;
			a += b;
			while (a > 0) {
				ans++;
				a /= 10;
			}
			System.out.println(ans);
		}
	}

	public static void main(String[] args) {
		new Main().run();
	}
} Main void run() {
		Scanner sc = new Scanner(System.in);

		while (sc.hasNext()) {
			int a = sc.nextInt();
			int b = sc.nextInt();

			int ans = 0;
			a += b;
			while (a > 0) {
				ans++;
				a /= 10;
			}
			System.out.println(ans);
		}
	} run {
		Scanner sc = new Scanner(System.in);

		while (sc.hasNext()) {
			int a = sc.nextInt();
			int b = sc.nextInt();

			int ans = 0;
			a += b;
			while (a > 0) {
				ans++;
				a /= 10;
			}
			System.out.println(ans);
		}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) while (sc.hasNext()) {
			int a = sc.nextInt();
			int b = sc.nextInt();

			int ans = 0;
			a += b;
			while (a > 0) {
				ans++;
				a /= 10;
			}
			System.out.println(ans);
		} sc.hasNext() sc.hasNext sc {
			int a = sc.nextInt();
			int b = sc.nextInt();

			int ans = 0;
			a += b;
			while (a > 0) {
				ans++;
				a /= 10;
			}
			System.out.println(ans);
		} int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int b = sc.nextInt(); b sc.nextInt() sc.nextInt sc int ans = 0; ans 0 a += b a b while (a > 0) {
				ans++;
				a /= 10;
			} a > 0 a 0 {
				ans++;
				a /= 10;
			} ans++ ans a /= 10 a 10 System.out.println(ans) System.out.println System.out System System.out ans public static void main(String[] args) {
		new Main().run();
	} main {
		new Main().run();
	} new Main().run() new Main().run new Main() String[] args args public class Main {
	void run() {
		Scanner sc = new Scanner(System.in);

		while (sc.hasNext()) {
			int a = sc.nextInt();
			int b = sc.nextInt();

			int ans = 0;
			a += b;
			while (a > 0) {
				ans++;
				a /= 10;
			}
			System.out.println(ans);
		}
	}

	public static void main(String[] args) {
		new Main().run();
	}
} public class Main {
	void run() {
		Scanner sc = new Scanner(System.in);

		while (sc.hasNext()) {
			int a = sc.nextInt();
			int b = sc.nextInt();

			int ans = 0;
			a += b;
			while (a > 0) {
				ans++;
				a /= 10;
			}
			System.out.println(ans);
		}
	}

	public static void main(String[] args) {
		new Main().run();
	}
} Main
import java.util.Scanner;

public class Main {
	void run() {
		Scanner sc = new Scanner(System.in);

		while (sc.hasNext()) {
			int a = sc.nextInt();
			int b = sc.nextInt();

			int ans = 0;
			a += b;
			while (a > 0) {
				ans++;
				a /= 10;
			}
			System.out.println(ans);
		}
	}

	public static void main(String[] args) {
		new Main().run();
	}
}