#include <iostream>
using namespace std;

int digit(int a, int b) {
	int sum = a+b;
	int d = 0;
	while (1) {
		sum /= 10;
		d++;
		if (sum == 0) break;
	}
	return d;
}

int main() {
	int a, b;
	while (1) {
		cin >> a >> b;
		cout << digit(a, b) << endl;
	}
	return 0;
}