#include <iostream>
using namespace std;
int solve(int a,int b){
    int sum=a+b,ans=0;
    while(sum>0){
        ans++;
        sum/=10;
    }
    return ans;
}
int main(void){
    int a[300]={},b[300]={},i=0;
    while(cin>>a[i]>>b[i]){
        cout<<solve(a[i],b[i])<<endl;
        i++;
    }
    return 0;
}