#include <iostream>
//#include <cstdio>
#include <cmath>
using namespace std;
  
//0002
int main(){
    int a, b, c;
    while(cin >> a >> b){
        c = a + b;
        cout << 1 + (int)log10(c) << endl;
    }
    return 0;
}