#include <iostream>
#include <vector>
using namespace std;

int digit_num(int num){
  int ret = 1;
  int base = 10;
  int rest = num / base;
  
  while(rest != 0){
    ret++;
    rest /= base;
  }
  
  return ret;
}

int main(){
  vector<int> ans;
  int a, b;
  
  while(cin >> a && cin >> b) ans.push_back(digit_num(a + b));
  
  for(int i = 0; i < (int)ans.size(); i++) cout << ans[i] << endl;
  
  return 0;
}