#include <iostream>
using namespace std;

int main()
{
	int a, b, i;
	int sum;
	
	while(cin >> a)
	{
		cin >> b;
	
		sum = a + b;
	
		i = 0;
		while(sum != 0)
		{
			sum = sum / 10;
			
			i = i + 1;
		}
		
		cout << i << endl;
		
	}
	
	return 0;
}