#include <iostream>
#include <string>
#include <sstream>
using namespace std;
int main() {
  int a, b, cnt;
  string s;
  getline(cin, s, ' ');
  a = stoi(s);
  getline(cin, s);
  b = stoi(s);
  a += b;
  cnt = 0;
  if (a == 0) {
    cnt = 1;
  } else {
    while (a) {
      cnt++;
      a /= 10;
    }
  }
  cout << cnt << endl;
  return 0;
}