// 2011/05/26 Tazoe

#include <iostream>
using namespace std;

int main()
{
	while(true){
		int a, b;
		cin >> a;
		if(cin.eof())
			break;
		cin >> b;

		int sum = a+b;

		int cnt = 0;
		while(sum>0){
			cnt++;
			sum /= 10;
		}

		cout << cnt << endl;
	}

	return 0;
}