import sys

for a in sys.stdin:

    b,c=list(map(int,a.split()))

    d=len(str(b+c))

    print(d)
import sys

a=[map(int,i.split())for i in sys.stdin]

[print(len(str(b+c)))for b,c in a]

import sys

for a in sys.stdin:
    b, c = list(map(int, a.split()))
    d = len(str(b + c))
    print(d)

import sys

a = [map(int, i.split()) for i in sys.stdin]
[print(len(str(b + c))) for b, c in a]

-for a in sys.stdin: -    b, c = list(map(int, a.split())) -    d = len(str(b + c)) -    print(d) +a = [map(int, i.split()) for i in sys.stdin] +[print(len(str(b + c))) for b, c in a]