var input = require('fs').readFileSync('/dev/stdin', 'utf8');
var Arr=(input.trim()).split("\n");
for(var i=0;i<Arr.length;i++){
var arr=Arr[i].split(" ").map(Number);
var ab=arr[0]+arr[1];
console.log((ab+"").length);