#include <stdio.h>
#include <iostream>
#include <algorithm>
#include <cmath>

using namespace std;

int main() {
	int sum;
	int x,y;
	int kekka;
	
	while(1){
		cin >> x >> y;
		if ( cin.eof() ) { break; }
		sum = x + y;
		kekka = (double)log10((double) sum)+1;
		cout << kekka << endl;
	}
	
    return 0;
}