#include <iostream>
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(){
  while(!cin.eof()){
    int a, b;
    cin >> a;
    cin >> b;

    int c = a + b;
    cout << digit_num(c) << endl;
  }

  return 0;
}