#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;

int dig(int n){
    if(n == 0)return 1;
    int ret = 0;
    while(n)ret++, n/=10;
    return ret;
}

int main(){
    int a, b;
    while(cin >> a >> b){
        int c = a + b;
        cout << dig(c) << endl;
    }
    return 0;
}