#include <iostream>
#include <string>

using namespace std;

int main(void) {
	int a, b;
	
	while(cin >> a) {
		cin >> b;
		
		int sum;
		char ch[20];
		string strSum = "";
		
		sum = a + b;
		
		sprintf(ch, "%d", sum);
		strSum += string(ch);
		
		cout << strSum.size() << endl;
		
	}
	
	return 0;
}