#include <iostream> 
#include <cstdio>
#include <sstream>

int main() {
  int a,b;
  while(scanf("%d %d", &a, &b) != EOF) {
    std::stringstream ss;
    ss << a+b;
    std::cout << ss.str().length() << std::endl;
  }
}