import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {

	public static void main(String[] args) throws IOException{
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		String input = r.readLine();
		while (input != null){
			String[] s = input.split(" ");
			int a = Integer.valueOf(s[0]);
			int b = Integer.valueOf(s[1]);
			System.out.println(String.valueOf(a+b).length());
			input = r.readLine();
		}
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {

	public static void main(String[] args) throws IOException{
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		String input = r.readLine();
		while (input != null){
			String[] s = input.split(" ");
			int a = Integer.valueOf(s[0]);
			int b = Integer.valueOf(s[1]);
			System.out.println(String.valueOf(a+b).length());
			input = r.readLine();
		}
	}
} Main public static void main(String[] args) throws IOException{
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		String input = r.readLine();
		while (input != null){
			String[] s = input.split(" ");
			int a = Integer.valueOf(s[0]);
			int b = Integer.valueOf(s[1]);
			System.out.println(String.valueOf(a+b).length());
			input = r.readLine();
		}
	} main {
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		String input = r.readLine();
		while (input != null){
			String[] s = input.split(" ");
			int a = Integer.valueOf(s[0]);
			int b = Integer.valueOf(s[1]);
			System.out.println(String.valueOf(a+b).length());
			input = r.readLine();
		}
	} BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1); r new BufferedReader(new InputStreamReader(System.in),1) String input = r.readLine(); input r.readLine() r.readLine r while (input != null){
			String[] s = input.split(" ");
			int a = Integer.valueOf(s[0]);
			int b = Integer.valueOf(s[1]);
			System.out.println(String.valueOf(a+b).length());
			input = r.readLine();
		} input != null input null {
			String[] s = input.split(" ");
			int a = Integer.valueOf(s[0]);
			int b = Integer.valueOf(s[1]);
			System.out.println(String.valueOf(a+b).length());
			input = r.readLine();
		} String[] s = input.split(" "); s input.split(" ") input.split input " " int a = Integer.valueOf(s[0]); a Integer.valueOf(s[0]) Integer.valueOf Integer s[0] s 0 int b = Integer.valueOf(s[1]); b Integer.valueOf(s[1]) Integer.valueOf Integer s[1] s 1 System.out.println(String.valueOf(a+b).length()) System.out.println System.out System System.out String.valueOf(a+b).length() String.valueOf(a+b).length String.valueOf(a+b) String.valueOf String a+b a b input = r.readLine() input r.readLine() r.readLine r String[] args args public class Main {

	public static void main(String[] args) throws IOException{
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		String input = r.readLine();
		while (input != null){
			String[] s = input.split(" ");
			int a = Integer.valueOf(s[0]);
			int b = Integer.valueOf(s[1]);
			System.out.println(String.valueOf(a+b).length());
			input = r.readLine();
		}
	}
} public class Main {

	public static void main(String[] args) throws IOException{
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		String input = r.readLine();
		while (input != null){
			String[] s = input.split(" ");
			int a = Integer.valueOf(s[0]);
			int b = Integer.valueOf(s[1]);
			System.out.println(String.valueOf(a+b).length());
			input = r.readLine();
		}
	}
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {

	public static void main(String[] args) throws IOException{
		BufferedReader r = new BufferedReader(new InputStreamReader(System.in),1);
		String input = r.readLine();
		while (input != null){
			String[] s = input.split(" ");
			int a = Integer.valueOf(s[0]);
			int b = Integer.valueOf(s[1]);
			System.out.println(String.valueOf(a+b).length());
			input = r.readLine();
		}
	}
}