#include <stdio.h>

int main(void)
{
	unsigned int a[2];
	int i;
	int b[2];
	int count;

	for(i = 0; i < 2; i++){
		scanf("%d", &a[i]);

		count = 0;
		do{
			count++;
		}while((a[i] = a[i]/10) > 0);

		b[i] = count;
	}

	printf("%d\n", b[0] + b[1]);
	
	return 0;
	
}