#include <iostream>
#include <string>
#include <sstream>

using namespace std;

int main()
{
	int a, b;
	while (cin >> a){
		cin >> b;
		auto sum = a + b;
		stringstream ss;
		ss << sum;
		string str(ss.str());
		cout << str.size() << endl;
	}
}