#include <cstdio>
#include <cstring>

int main() {
    int a, b;
    char nah[100];
    while ( scanf("%d %d", &a, &b) != EOF ) {
          sprintf(nah, "%d", a + b);
          printf("%d\n", strlen(nah));
    }
    return 0;
}