(function Main() {
var input = require("fs").readFileSync("/dev/stdin", "utf8");
	input = input.split("\n");
  for(var i = 0; i < 3; i++){
    var tmp=input[i].split(" ");
	var b = parseInt(tmp[0], 10);
	var c = parseInt(tmp[1], 10);
    var a=b+c+"";
    console.log(a.length);
  }
})();

