#include<iostream>
using namespace std;
int main() {
	int a, b, ans[300], i, z;
	z = 0;
	while (cin >> a >> b) {
		z++;
		a = a + b;
		b = 0;
		while (a != 0) {
			a = a / 10;
			b++;
		}
		ans[z] = b;
	}
	for (i = 1; i <= z; i++) {
		cout << ans[i] << endl;
	}
}
