let _ =
  try
    while true do
      let a, b = Scanf.scanf "%d %d\n" (fun x y -> (x,y)) in
      let rec digit_number r n =
        let m = (n / 10) in
        if m = 0 then r else digit_number (r + 1) m in
      Printf.printf "%d\n" (digit_number 1 (a+b))
    done
  with
    End_of_file -> ()