#include <iostream>
#include <cmath>

using namespace std;

int main (void) {
    int a, b, sum;
    while (1) {
        cin >> a;
        cin >> b;
        if (cin.eof()) break;
        sum = a + b;
        if (sum == 0) cout << 1 << endl;
        else cout << (int)(log10(sum) + 1) << endl;
    }
    return 0;
}