#define _CRT_SECURE_NO_WARNINGS
#include<stdio.h>

int main() {
	int a, b, sum, digit;

	while (1) { 
		digit = 0;
		scanf("%d %d", &a, &b);
		sum = a + b;
		while (sum > 0) {
			sum /= 10;
			digit++;
		}
		printf("%d\n", digit);
	}

	return 0;
}