#include<cstdio>
#include<string.h>
int main(){
   int a,b;
   char s[256],cmd[256];
   while(1){
             fgets(s,256,stdin);
             sscanf(s,"%s",cmd);
             if(strcmp(cmd,"EOF")==0){  
                        break;
             }
  
             sscanf(s,"%d %d",&a,&b);
             int c=a+b,counter=0;
             while( ((int)c/10)>=1){
                         counter++;
                         c=(int)c/10;
              }

              printf("%d\n",counter+1);
   }
  return 0;
}