#!/usr/bin/env python3
#coding: utf-8

# Volume0 - 0002 (http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0002)

while 1:
    try:
        i = input()
        l = i.split(" ")
        s = int(l[0]) + int(l[1])
        ans = len(str(s))
        print(ans)
    except:
        break while 1:
    try:
        i = input()
        l = i.split(" ")
        s = int(l[0]) + int(l[1])
        ans = len(str(s))
        print(ans)
    except:
        break 1 try:
        i = input()
        l = i.split(" ")
        s = int(l[0]) + int(l[1])
        ans = len(str(s))
        print(ans)
    except:
        break except:
        break break i = input() i input() input l = i.split(" ") l i.split(" ") i.split i split " " s = int(l[0]) + int(l[1]) s int(l[0]) + int(l[1]) int(l[0]) int l[0] l 0 int(l[1]) int l[1] l 1 ans = len(str(s)) ans len(str(s)) len str(s) str s print(ans) print ans i = input() input() i l = i.split(" ") i.split(" ") l s = int(l[0]) + int(l[1]) int(l[0]) + int(l[1]) s ans = len(str(s)) len(str(s)) ans
#!/usr/bin/env python3
#coding: utf-8

# Volume0 - 0002 (http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0002)

while 1:
    try:
        i = input()
        l = i.split(" ")
        s = int(l[0]) + int(l[1])
        ans = len(str(s))
        print(ans)
    except:
        break