#include <bits/stdc++.h>
using namespace std;
#define IOS ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
typedef long long ll;
// Welcome to my source code!

int main() {
    int a, b;
    while (cin >> a >> b) {
        int t = a + b;
        int digit = (a + b ? 1 : 0);
        while (t / 10) {
            t /= 10;
            digit++;
        }
        cout << digit << endl;
    }
}
