import Control.Applicative
import System.IO

main :: IO ()
main = do
    end <- isEOF
    if end 
    then print ""
    else do
        a:b:_ <- (map read . words) <$> getLine
        print $ solve a b

solve :: Int -> Int -> Int
solve a b = length $ show (a + b)
