#condig: UTF-8

while True:
    try:
        n = map(int, raw_input().split())
        s = len(str(n[0] + n[1]))
        print s
    except Exception:
        break while True:
    try:
        n = map(int, raw_input().split())
        s = len(str(n[0] + n[1]))
        print s
    except Exception:
        break True try:
        n = map(int, raw_input().split())
        s = len(str(n[0] + n[1]))
        print s
    except Exception:
        break except Exception:
        break break n = map(int, raw_input().split()) n map(int, raw_input().split()) map int raw_input().split() ().split () raw_input split s = len(str(n[0] + n[1])) s len(str(n[0] + n[1])) len str(n[0] + n[1]) str n[0] + n[1] n[0] n 0 n[1] n 1 print s = len(str(n[0] + n[1])) len(str(n[0] + n[1])) s n = map(int, raw_input().split()) map(int, raw_input().split()) n
#condig: UTF-8

while True:
    try:
        n = map(int, raw_input().split())
        s = len(str(n[0] + n[1]))
        print s
    except Exception:
        break