import java.util.Scanner;

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

	public static void main(String[] args) {
		while(sc.hasNext()) {
			String[] numbers = sc.nextLine().split(" ");

			Integer ans = Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]);
			System.out.println(String.valueOf(ans).length());
		}

	}

} import java.util.Scanner; Scanner java.util public class Main {
	static Scanner sc = new Scanner(System.in);

	public static void main(String[] args) {
		while(sc.hasNext()) {
			String[] numbers = sc.nextLine().split(" ");

			Integer ans = Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]);
			System.out.println(String.valueOf(ans).length());
		}

	}

} Main static Scanner sc = new Scanner(System.in); sc new Scanner(System.in) public static void main(String[] args) {
		while(sc.hasNext()) {
			String[] numbers = sc.nextLine().split(" ");

			Integer ans = Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]);
			System.out.println(String.valueOf(ans).length());
		}

	} main {
		while(sc.hasNext()) {
			String[] numbers = sc.nextLine().split(" ");

			Integer ans = Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]);
			System.out.println(String.valueOf(ans).length());
		}

	} while(sc.hasNext()) {
			String[] numbers = sc.nextLine().split(" ");

			Integer ans = Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]);
			System.out.println(String.valueOf(ans).length());
		} sc.hasNext() sc.hasNext sc {
			String[] numbers = sc.nextLine().split(" ");

			Integer ans = Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]);
			System.out.println(String.valueOf(ans).length());
		} String[] numbers = sc.nextLine().split(" "); numbers sc.nextLine().split(" ") sc.nextLine().split sc.nextLine() sc.nextLine sc " " Integer ans = Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]); ans Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]) Integer.parseInt(numbers[0]) Integer.parseInt Integer numbers[0] numbers 0 Integer.parseInt(numbers[1]) Integer.parseInt Integer numbers[1] numbers 1 System.out.println(String.valueOf(ans).length()) System.out.println System.out System System.out String.valueOf(ans).length() String.valueOf(ans).length String.valueOf(ans) String.valueOf String ans String[] args args public class Main {
	static Scanner sc = new Scanner(System.in);

	public static void main(String[] args) {
		while(sc.hasNext()) {
			String[] numbers = sc.nextLine().split(" ");

			Integer ans = Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]);
			System.out.println(String.valueOf(ans).length());
		}

	}

} public class Main {
	static Scanner sc = new Scanner(System.in);

	public static void main(String[] args) {
		while(sc.hasNext()) {
			String[] numbers = sc.nextLine().split(" ");

			Integer ans = Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]);
			System.out.println(String.valueOf(ans).length());
		}

	}

} Main
import java.util.Scanner;

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

	public static void main(String[] args) {
		while(sc.hasNext()) {
			String[] numbers = sc.nextLine().split(" ");

			Integer ans = Integer.parseInt(numbers[0]) + Integer.parseInt(numbers[1]);
			System.out.println(String.valueOf(ans).length());
		}

	}

}