#include<cstdio>
#include<vector>
#include<algorithm>
using namespace std;
int main(void){
	int a;
	int b;
	int n;
	int s;
	int c;

 	while (scanf("%d %d", &a,&b) != EOF){
		s = a + b;
		if (s == 0)printf("1\n");
		else{
			for (int i=1;i<10;i++){
				s = s / 10;
				if (s == 0){
					printf("%d\n", i);
					break;
				}
			}
		}

	}

		return 0;
	}