#include<stdio.h>


int main(void){
  int a,b,c,d,e,i,j;
  int n[9999];
  j=0;  
  while(scanf(" %d %d", &a, &b)!=EOF){
   
    c=a+b;d=1;i=0;e=1;
    while(e>0){
      e=c/d;
      //      printf("%d\n",i);
      d=d*10;
      i++;}
    n[j]=i-1;
    
    //printf("input %d %d \n",a,b);
    j++;
  }
  for(i=0;i<j;i++)
    printf("%d\n",n[i]);
	   return 0;
}