#include<iostream>
using namespace std;
int main()
{
	while (true)
	{
		int a, b;
		cin >> a >> b;
		if (cin.fail())
			break;
		int cnt = 0;
		int x = a + b;
		do {
			x /= 10;
			cnt++;
		} while (x);
		cout << cnt << endl;
	}
}
