#include <iostream>
#include <string>
#include <algorithm>
#include <utility>
#include <stack>
#include <queue>
#include <vector>
#include <cmath>

#define pb push_back

using namespace std;

typedef long long ll;

int main()
{
        int a, b;
        while(cin >> a){
                cin >> b;
                if(a + b == 0) cout << 1 << endl;
                cout << (int)log10(a+b) + 1 << endl;
        }

        return 0;
}
