//http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0002

#include <iostream>
#include <string>
using namespace std;
int main() {
	int a, b; 
	while (cin >> a >> b) {
		string str = to_string(a + b);
		cout << str.length() << endl;
	}
}