#include <iostream>
#include <cstdio>
#include <cstdlib>
#include <string>

using namespace std;

int main()
{
	int a, b;

	while(cin >> a >> b){
		a = a+b; b=0;
		while(true){
			if(a==0){cout << b << endl; break;}
			a=a/10; b++;
		}
	}

	return 0;
}