#include<stdio.h>
#include<math.h>
int array[100];
int counter(long long int a,long long int b);
int main()
{
    long long int a,b;
    int count;
    while(scanf("%lld %lld",&a,&b)==2)
    {
        count=counter(a,b);
        printf("%d\n",count);
    }
    return(0);
}
int counter(long long int a,long long int b)
{
    long long int number;
    int x,count=0;
    number=a+b;
    if(number==0)
    {
        count=1;
        return(count);
    }
    else
    {

        while(number!=0)
        {
            count++;
            number=number/10;
        }
        return(count);
    }
}