#include <stdio.h>
#include <stdlib.h>

int main(void){
  int c, i = 0, a, b, d;
  char tmp[8]; // 0 - 1000000
  while((c = getchar()) != EOF){
    tmp[i++] = c;
    if(c == ' '){
      tmp[i] = '\0';
      a = atoi(tmp);
      i = 0;
    }
  }
  tmp[i] = '\0';
  b = atoi(tmp);

  d = a + b;
  for(i = 0; d !=0; i++){
    d /= 10;
  }
  printf("%d\n", i + 1);
  return 0;
}