#include <iostream>
using namespace std;
int main( void )
{
  int x,y,z;
  while( 1 ){
    cin >> x >> y;
    if( cin.eof() ) break;
    x += y;
    z = 0;
    if( x == 0 ) z = 1;
    while( x > 0 ){
      z++;
      x /= 10;
    }
    cout << z << endl;
  }
  return 0;
}