#include <iostream>

int main(int argc, const char * argv[]) {
    
    using namespace std;
    int a;
    int b;
    int sum;
    int flag = 0;
    int count = 0;
    
    cin >> a >> b;
    
    sum = a + b;
    
    while (!flag) {
        sum = sum / 10;
        count++;
        if(sum < 1) flag = 1;
    }
    
    cout << count;
    
    return 0;
}