#include <iostream>
#include <string>
#include <vector>

using namespace std;

static int count_digit(const int a, const int b) {
	return to_string(a + b).length();
}

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

