import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class Main {
	public static void main(String[] args) {
		try {
			Pattern pattern = Pattern.compile("([0-9]+) *([0-9]+)");
			BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
			Matcher matcher;
			String temp;
			int sum;
			while((temp = bf.readLine() ) != null){
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			}
		}catch(Exception e){
			System.out.println(e);
		}
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io import java.util.regex.Matcher; Matcher java.util.regex import java.util.regex.Pattern; Pattern java.util.regex public class Main {
	public static void main(String[] args) {
		try {
			Pattern pattern = Pattern.compile("([0-9]+) *([0-9]+)");
			BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
			Matcher matcher;
			String temp;
			int sum;
			while((temp = bf.readLine() ) != null){
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			}
		}catch(Exception e){
			System.out.println(e);
		}
	}
} Main public static void main(String[] args) {
		try {
			Pattern pattern = Pattern.compile("([0-9]+) *([0-9]+)");
			BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
			Matcher matcher;
			String temp;
			int sum;
			while((temp = bf.readLine() ) != null){
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			}
		}catch(Exception e){
			System.out.println(e);
		}
	} main {
		try {
			Pattern pattern = Pattern.compile("([0-9]+) *([0-9]+)");
			BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
			Matcher matcher;
			String temp;
			int sum;
			while((temp = bf.readLine() ) != null){
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			}
		}catch(Exception e){
			System.out.println(e);
		}
	} try {
			Pattern pattern = Pattern.compile("([0-9]+) *([0-9]+)");
			BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
			Matcher matcher;
			String temp;
			int sum;
			while((temp = bf.readLine() ) != null){
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			}
		}catch(Exception e){
			System.out.println(e);
		} catch(Exception e){
			System.out.println(e);
		} Exception e {
			System.out.println(e);
		} System.out.println(e) System.out.println System.out System System.out e {
			Pattern pattern = Pattern.compile("([0-9]+) *([0-9]+)");
			BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
			Matcher matcher;
			String temp;
			int sum;
			while((temp = bf.readLine() ) != null){
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			}
		} Pattern pattern = Pattern.compile("([0-9]+) *([0-9]+)"); pattern Pattern.compile("([0-9]+) *([0-9]+)") Pattern.compile Pattern "([0-9]+) *([0-9]+)" BufferedReader bf = new BufferedReader(new InputStreamReader(System.in)); bf new BufferedReader(new InputStreamReader(System.in)) Matcher matcher; matcher String temp; temp int sum; sum while((temp = bf.readLine() ) != null){
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			} (temp = bf.readLine() ) != null (temp = bf.readLine() ) temp bf.readLine() bf.readLine bf null {
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			} if(temp.length()==0)break; temp.length()==0 temp.length() temp.length temp 0 break; matcher = pattern.matcher(temp) matcher pattern.matcher(temp) pattern.matcher pattern temp if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				} matcher.matches() matcher.matches matcher {
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				} sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2)) sum Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2)) Integer.parseInt(matcher.group(1)) Integer.parseInt Integer matcher.group(1) matcher.group matcher 1 Integer.parseInt(matcher.group(2)) Integer.parseInt Integer matcher.group(2) matcher.group matcher 2 temp=Integer.toString(sum) temp Integer.toString(sum) Integer.toString Integer sum System.out.println(temp.length()) System.out.println System.out System System.out temp.length() temp.length temp String[] args args public class Main {
	public static void main(String[] args) {
		try {
			Pattern pattern = Pattern.compile("([0-9]+) *([0-9]+)");
			BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
			Matcher matcher;
			String temp;
			int sum;
			while((temp = bf.readLine() ) != null){
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			}
		}catch(Exception e){
			System.out.println(e);
		}
	}
} public class Main {
	public static void main(String[] args) {
		try {
			Pattern pattern = Pattern.compile("([0-9]+) *([0-9]+)");
			BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
			Matcher matcher;
			String temp;
			int sum;
			while((temp = bf.readLine() ) != null){
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			}
		}catch(Exception e){
			System.out.println(e);
		}
	}
} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class Main {
	public static void main(String[] args) {
		try {
			Pattern pattern = Pattern.compile("([0-9]+) *([0-9]+)");
			BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
			Matcher matcher;
			String temp;
			int sum;
			while((temp = bf.readLine() ) != null){
				if(temp.length()==0)break;
				matcher = pattern.matcher(temp);
				if(matcher.matches()){
					sum=Integer.parseInt(matcher.group(1))+Integer.parseInt(matcher.group(2));
					temp=Integer.toString(sum);
					System.out.println(temp.length());
				}
			}
		}catch(Exception e){
			System.out.println(e);
		}
	}
}