#include <iostream>

using namespace std;

int main() {
	int a,b,c,ans;
	for(int i = 0; i < 200; i++){
		cin >> a >> b;
		if(0 <= a && 0 <= b && b <= 1000000){
		ans = 0;
		c = a + b;
		while(c!=0){
		c = c / 10;

		++ans;
	}
	}
	cout << ans << endl;
	}
	return 0;
}