while True:
    try:print(len(str(sum(map(int,input().split())))))
    except:break while True:
    try:print(len(str(sum(map(int,input().split())))))
    except:break True try:print(len(str(sum(map(int,input().split())))))
    except:break except:b
while True:
    try:print(len(str(sum(map(int,input().split())))))
    except:break
