#include<iostream>
using namespace std;
int main(){
	int a;
	int b;
	while(1){
		cin >> a >> b;
		if(a == EOF){
			exit(0);
		}
		a += b;
		int count = 0;
		while(a>0){
            a/=10;
            count++;
        }

        cout << count << endl;
    }
    return 0;
}