#include<iostream>
using namespace std;

int main(){
	int a[200], b[200], damy, i;

	for(i = 0; i < 200; i++){
		cin >> a[i] >> b[i];
	}

	for(i = 0; i < 200; i++){
		damy = a[i] + b[i];
		for(int k = 0; damy != 0; k++){
			damy /= 10;
			cout << k <<endl;
		}
	}

	return 0;
}