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

int main() {
  std::cin.tie(0);
  std::ios::sync_with_stdio(false);

  int a, b;
  while (cin >> a, cin >> b) {
    cout << ceil(log10(a + b)) << endl;
  }

  return 0;
}