
process.stdin.resume();
process.stdin.setEncoding('utf8');
process.stdin.on('data', function(chunk){
 var array = chunk.split("\n")

 for (var i = 0; i < array.length; i++) {
   var x = array.split(" ").map(Number)
   var xa = x[0] + x[1]
   console.log(String(xa).length)
 }



 })