#include<bits/stdc++.h>

using namespace std;
typedef long long ll;

int main(){
    
    ios_base::sync_with_stdio(0);
    int a,b;
    while(scanf("%d %d" , &a,&b) != EOF){
        //cin>>a>>b;
        ll sum = a+b;
        int cnt=0;
        string res="";
        while(sum){
            res += ((sum%10)+'0');
            sum /= 10;
        }
        cout<<res.length()<<endl;
    }
    return 0;
}


