#include <iostream>
using namespace std;
unsigned short digitsofnum(unsigned short n) {
	int j = 0;
	while (n > 0) {
		n = n / 10;
		j++;
	}
	return j;
}
int main()
{
	unsigned short a, b;
	vector<unsigned short> dst;
	while (cin >> a >> b)
		cout <<digitsofnum(a + b) << endl;
	return 0;
}
