#include<iostream>
#include<cstdio>
#include<stdio.h>
#include<string>
using namespace std;
int main() {
	long x,y,i, j=0,k=0, a, b;
	while (cin >> a >> b) {
		x = a + b;
		while (1) {
			j++;
			x /= 10;
			if (x == 0) {
				y = j;
				j = 0;
				break;
			}
		}
		cout << y << endl;
		
	}

	return 0;
}