#include<iostream>
#include<string.h>
#include<math.h>
using namespace std;

//get digit(return int)
int get_digit(int num){
    int digit = 0;
    while(num > 0){
        num = num/10;
        digit++;
    }
    return digit;
}

int main(){
    int a, b;
    int answer[200];
    int size = 0;

    while(cin >> a >> b){
        if(size > 200){
            break;
        }
        answer[size] = get_digit(a + b);
        size++;
    }
    for(int i = 0;i < size;i++){
        cout << answer[i] << "\n";
    }
    return 0;
}
