#include <iostream>
using namespace std;

int c = 0;

void keta(int A) {
	if (A > 9) {
		c++;
		keta(A/10);
	}
	return;
}

int main()
{
	int A, B,C;
	while (cin >> A >> B) {
		c = 0;
		A += B;
		keta(A);
		c++;
		cout << c <<endl;
	}
    return 0;
}