#include <cstdio>
#include <cstdlib>
#include <cmath>
#include <climits>
#include <cfloat>
#include <map>
#include <utility>
#include <set>
#include <iostream>
#include <memory>
#include <string>
#include <vector>
#include <algorithm>
#include <functional>
#include <sstream>
#include <complex>
#include <stack>
#include <queue>
using namespace std;
typedef long long ll;
typedef vector<int> vint;
typedef pair<int, int> pint;
#define MOD 1000000007 //10^9+7
#define INF 1000000000 //10^9

int main ()
{
    string str;
    while (getline(cin,str)) {
        bool f=0;
        int a=0,b=0;
        for (int i=0; i<(int)str.length(); i++) {
            if (str[i]==' ') f=1;
            else if (!f) a=a*10+(str[i]-'0');
            else b=b*10+(str[i]-'0');
        }
        cout<<(int)log10(a+b)+1<<endl;
    }
}