#include <iostream>
using namespace std;
int main(){
     long long a,b;
    while(1){
        cin >> a >> b;
        if(cin.eof()){
            break;
        }
        long long sum = a + b;
        int cnt = 1;
        while(sum/10>=1){
            sum/=10;
            cnt++;
        }
        cout << cnt << endl;
    }
    return 0;
}