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

public class Main {
	public static void main(String[] args) throws IOException {
		for (int[] n = readInts(); n != null; n = readInts()) {
			int val = n[0] + n[1];
			System.out.println(Integer.toString(val).length());
		}
	}

	static BufferedReader br = new BufferedReader(new InputStreamReader(
			System.in));

	private static int[] readInts() throws IOException {
		String readLine = br.readLine();
		if (readLine == null) {
			return null;
		}
		String[] s = readLine.split(" ");
		int[] result = new int[s.length];
		for (int i = 0; i < result.length; i++)
			result[i] = Integer.parseInt(s[i], 10);

		return result;
	}
} 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 {
		for (int[] n = readInts(); n != null; n = readInts()) {
			int val = n[0] + n[1];
			System.out.println(Integer.toString(val).length());
		}
	}

	static BufferedReader br = new BufferedReader(new InputStreamReader(
			System.in));

	private static int[] readInts() throws IOException {
		String readLine = br.readLine();
		if (readLine == null) {
			return null;
		}
		String[] s = readLine.split(" ");
		int[] result = new int[s.length];
		for (int i = 0; i < result.length; i++)
			result[i] = Integer.parseInt(s[i], 10);

		return result;
	}
} Main static BufferedReader br = new BufferedReader(new InputStreamReader(
			System.in)); br new BufferedReader(new InputStreamReader(
			System.in)) public static void main(String[] args) throws IOException {
		for (int[] n = readInts(); n != null; n = readInts()) {
			int val = n[0] + n[1];
			System.out.println(Integer.toString(val).length());
		}
	} main {
		for (int[] n = readInts(); n != null; n = readInts()) {
			int val = n[0] + n[1];
			System.out.println(Integer.toString(val).length());
		}
	} for (int[] n = readInts(); n != null; n = readInts()) {
			int val = n[0] + n[1];
			System.out.println(Integer.toString(val).length());
		} int[] n = readInts(); int[] n = readInts(); n readInts() readInts n != null n null n = readInts() n = readInts() n readInts() readInts {
			int val = n[0] + n[1];
			System.out.println(Integer.toString(val).length());
		} {
			int val = n[0] + n[1];
			System.out.println(Integer.toString(val).length());
		} int val = n[0] + n[1]; val n[0] + n[1] n[0] n 0 n[1] n 1 System.out.println(Integer.toString(val).length()) System.out.println System.out System System.out Integer.toString(val).length() Integer.toString(val).length Integer.toString(val) Integer.toString Integer val String[] args args private static int[] readInts() throws IOException {
		String readLine = br.readLine();
		if (readLine == null) {
			return null;
		}
		String[] s = readLine.split(" ");
		int[] result = new int[s.length];
		for (int i = 0; i < result.length; i++)
			result[i] = Integer.parseInt(s[i], 10);

		return result;
	} readInts {
		String readLine = br.readLine();
		if (readLine == null) {
			return null;
		}
		String[] s = readLine.split(" ");
		int[] result = new int[s.length];
		for (int i = 0; i < result.length; i++)
			result[i] = Integer.parseInt(s[i], 10);

		return result;
	} String readLine = br.readLine(); readLine br.readLine() br.readLine br if (readLine == null) {
			return null;
		} readLine == null readLine null {
			return null;
		} return null; null String[] s = readLine.split(" "); s readLine.split(" ") readLine.split readLine " " int[] result = new int[s.length]; result new int[s.length] s.length s s.length for (int i = 0; i < result.length; i++)
			result[i] = Integer.parseInt(s[i], 10); int i = 0; int i = 0; i 0 i < result.length i result.length result result.length i++ i++ i result[i] = Integer.parseInt(s[i], 10); result[i] = Integer.parseInt(s[i], 10) result[i] result i Integer.parseInt(s[i], 10) Integer.parseInt Integer s[i] s i 10 return result; result public class Main {
	public static void main(String[] args) throws IOException {
		for (int[] n = readInts(); n != null; n = readInts()) {
			int val = n[0] + n[1];
			System.out.println(Integer.toString(val).length());
		}
	}

	static BufferedReader br = new BufferedReader(new InputStreamReader(
			System.in));

	private static int[] readInts() throws IOException {
		String readLine = br.readLine();
		if (readLine == null) {
			return null;
		}
		String[] s = readLine.split(" ");
		int[] result = new int[s.length];
		for (int i = 0; i < result.length; i++)
			result[i] = Integer.parseInt(s[i], 10);

		return result;
	}
} public class Main {
	public static void main(String[] args) throws IOException {
		for (int[] n = readInts(); n != null; n = readInts()) {
			int val = n[0] + n[1];
			System.out.println(Integer.toString(val).length());
		}
	}

	static BufferedReader br = new BufferedReader(new InputStreamReader(
			System.in));

	private static int[] readInts() throws IOException {
		String readLine = br.readLine();
		if (readLine == null) {
			return null;
		}
		String[] s = readLine.split(" ");
		int[] result = new int[s.length];
		for (int i = 0; i < result.length; i++)
			result[i] = Integer.parseInt(s[i], 10);

		return result;
	}
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {
	public static void main(String[] args) throws IOException {
		for (int[] n = readInts(); n != null; n = readInts()) {
			int val = n[0] + n[1];
			System.out.println(Integer.toString(val).length());
		}
	}

	static BufferedReader br = new BufferedReader(new InputStreamReader(
			System.in));

	private static int[] readInts() throws IOException {
		String readLine = br.readLine();
		if (readLine == null) {
			return null;
		}
		String[] s = readLine.split(" ");
		int[] result = new int[s.length];
		for (int i = 0; i < result.length; i++)
			result[i] = Integer.parseInt(s[i], 10);

		return result;
	}
}