#include <iostream>
#include <algorithm>
using namespace std;
int main(){
    int i,o,b=0,f;
    while(cin>>i>>o){
        f=i+o;
        for(int j=1;j<=1000000;j=j*10){
            if(f>=j){
                b++;
            }else{
                break;
            }
        }
        cout<<b<<endl;
        b=0;
    }
    return 0;
}