#include<iostream>

using namespace std;

int main()
{
	int a,b;
	for(int i =0;i < 200;i++)
	{
		cin >> a >> b;
		a += b;
		int count = 0;
		while(true)
		{
			count++;
			if(a / 10 == 0)
			{
				break;
			}
			a = a / 10;
		}
		cout << count << endl;
		a = b = count = 0;
	}
}