import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        try (Scanner in = new Scanner(System.in)) {
            solve(in);
        }
    }

    private static void solve(Scanner in) {
        while (in.hasNext()) {
            int a = in.nextInt(), b = in.nextInt();
            String s = (a + b) + "";
            System.out.println(s.length());
        }
    }
} import java.util.Scanner; Scanner java.util public class Main {

    public static void main(String[] args) {
        try (Scanner in = new Scanner(System.in)) {
            solve(in);
        }
    }

    private static void solve(Scanner in) {
        while (in.hasNext()) {
            int a = in.nextInt(), b = in.nextInt();
            String s = (a + b) + "";
            System.out.println(s.length());
        }
    }
} Main public static void main(String[] args) {
        try (Scanner in = new Scanner(System.in)) {
            solve(in);
        }
    } main {
        try (Scanner in = new Scanner(System.in)) {
            solve(in);
        }
    } try (Scanner in = new Scanner(System.in)) {
            solve(in);
        } {
            solve(in);
        } Scanner in = new Scanner(System.in) Scanner in = new Scanner(System.in) new Scanner(System.in) solve(in) solve in String[] args args private static void solve(Scanner in) {
        while (in.hasNext()) {
            int a = in.nextInt(), b = in.nextInt();
            String s = (a + b) + "";
            System.out.println(s.length());
        }
    } solve {
        while (in.hasNext()) {
            int a = in.nextInt(), b = in.nextInt();
            String s = (a + b) + "";
            System.out.println(s.length());
        }
    } while (in.hasNext()) {
            int a = in.nextInt(), b = in.nextInt();
            String s = (a + b) + "";
            System.out.println(s.length());
        } in.hasNext() in.hasNext in {
            int a = in.nextInt(), b = in.nextInt();
            String s = (a + b) + "";
            System.out.println(s.length());
        } int a = in.nextInt() a in.nextInt() in.nextInt in b = in.nextInt(); b in.nextInt() in.nextInt in String s = (a + b) + ""; s (a + b) + "" (a + b) a b "" System.out.println(s.length()) System.out.println System.out System System.out s.length() s.length s Scanner in in public class Main {

    public static void main(String[] args) {
        try (Scanner in = new Scanner(System.in)) {
            solve(in);
        }
    }

    private static void solve(Scanner in) {
        while (in.hasNext()) {
            int a = in.nextInt(), b = in.nextInt();
            String s = (a + b) + "";
            System.out.println(s.length());
        }
    }
} public class Main {

    public static void main(String[] args) {
        try (Scanner in = new Scanner(System.in)) {
            solve(in);
        }
    }

    private static void solve(Scanner in) {
        while (in.hasNext()) {
            int a = in.nextInt(), b = in.nextInt();
            String s = (a + b) + "";
            System.out.println(s.length());
        }
    }
} Main
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        try (Scanner in = new Scanner(System.in)) {
            solve(in);
        }
    }

    private static void solve(Scanner in) {
        while (in.hasNext()) {
            int a = in.nextInt(), b = in.nextInt();
            String s = (a + b) + "";
            System.out.println(s.length());
        }
    }
}