#include <iostream>
#include <cmath>
#include <array>

template<class T>
T input()
{
	T val;
	std::cin >> val;
	return val;
}

int main()
{
	std::array<int, 200> hoge;
	for (int i = 0; i < 200; ++i)
		hoge[i] = input<int>() + input<int>();

	for (int i = 0; i < 200; ++i)
		std::cout << static_cast<int>(log10(hoge[i])) + 1 << std::endl;
	return 0;
}