import sys


def main():
    for line in sys.stdin.readlines():
        a,b = [int(n) for n in line.split()]
        ret = a + b
        print len(str(ret))


main() import sys sys def main():
    for line in sys.stdin.readlines():
        a,b = [int(n) for n in line.split()]
        ret = a + b
        print len(str(ret)) main for line in sys.stdin.readlines():
        a,b = [int(n) for n in line.split()]
        ret = a + b
        print len(str(ret)) line sys.stdin.readlines() sys.stdin.readlines sys.stdin sys stdin readlines int(n) for n in line.split() for n in line.split() n line.split() line.split line split for n in line.split() int(n) int n a,b = [int(n) for n in line.split()] a [int(n) for n in line.split()] b ret = a + b ret a + b a b print len(str(ret)) len str(ret) str ret main() main def main():
    for line in sys.stdin.readlines():
        a,b = [int(n) for n in line.split()]
        ret = a + b
        print len(str(ret)) def main():
    for line in sys.stdin.readlines():
        a,b = [int(n) for n in line.split()]
        ret = a + b
        print len(str(ret)) main
import sys


def main():
    for line in sys.stdin.readlines():
        a,b = [int(n) for n in line.split()]
        ret = a + b
        print len(str(ret))


main()