import java.util.Scanner;

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

	public static void main(String[] args) {
		
		while ( sc.hasNext() ){
		
		int a = sc.nextInt();
		int b = sc.nextInt();

		int s = a + b ;
		String str = Integer.toString( s );
		
		System.out.println( str.length() );
	
		}

	}

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

	public static void main(String[] args) {
		
		while ( sc.hasNext() ){
		
		int a = sc.nextInt();
		int b = sc.nextInt();

		int s = a + b ;
		String str = Integer.toString( s );
		
		System.out.println( str.length() );
	
		}

	}

} Main static Scanner sc =  new java.util.Scanner(System.in); sc new java.util.Scanner(System.in) public static void main(String[] args) {
		
		while ( sc.hasNext() ){
		
		int a = sc.nextInt();
		int b = sc.nextInt();

		int s = a + b ;
		String str = Integer.toString( s );
		
		System.out.println( str.length() );
	
		}

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

		int s = a + b ;
		String str = Integer.toString( s );
		
		System.out.println( str.length() );
	
		}

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

		int s = a + b ;
		String str = Integer.toString( s );
		
		System.out.println( str.length() );
	
		} sc.hasNext() sc.hasNext sc {
		
		int a = sc.nextInt();
		int b = sc.nextInt();

		int s = a + b ;
		String str = Integer.toString( s );
		
		System.out.println( str.length() );
	
		} int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int b = sc.nextInt(); b sc.nextInt() sc.nextInt sc int s = a + b ; s a + b a b String str = Integer.toString( s ); str Integer.toString( s ) Integer.toString Integer s System.out.println( str.length() ) System.out.println System.out System System.out str.length() str.length str String[] args args public class Main {
	static Scanner sc =  new java.util.Scanner(System.in);

	public static void main(String[] args) {
		
		while ( sc.hasNext() ){
		
		int a = sc.nextInt();
		int b = sc.nextInt();

		int s = a + b ;
		String str = Integer.toString( s );
		
		System.out.println( str.length() );
	
		}

	}

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

	public static void main(String[] args) {
		
		while ( sc.hasNext() ){
		
		int a = sc.nextInt();
		int b = sc.nextInt();

		int s = a + b ;
		String str = Integer.toString( s );
		
		System.out.println( str.length() );
	
		}

	}

} Main
import java.util.Scanner;

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

	public static void main(String[] args) {
		
		while ( sc.hasNext() ){
		
		int a = sc.nextInt();
		int b = sc.nextInt();

		int s = a + b ;
		String str = Integer.toString( s );
		
		System.out.println( str.length() );
	
		}

	}

}