Go: package main

import (
	"bufio"
	"fmt"
	"os"
	"strconv"
	"strings"
)

var (
	sc = bufio.NewScanner(os.Stdin)
)

func main() {
	for sc.Scan() {
		chunks := strings.Split(sc.Text(), " ")
		if len(chunks) != 2 {
			break
		}
		a, _ := strconv.Atoi(chunks[0])
		b, _ := strconv.Atoi(chunks[1])
		fmt.Println(a + b)
	}
}

C++: #include <iostream>
using namespace std;
int main()
{
    int a, b;
    while(cin >> a >> b){
        int num = a + b;
        int count = 0;
        while(num){
            count++;
            num /= 10;
        }
        cout << count << endl;
    }
    return(0);
}

C++: #include<iostream>
#include<vector>

int main(void){
    std::vector<int> a,b;
    int x,y,z;
    while(std::cin>>x>>y){
      a.push_back(x);
      b.push_back(y);
    }
    for(int i=0;i<a.size();i++){
     int c=0;
     z=a[i]+b[i];
      while(z!=0){
        z = z/10;
        ++c;
      }
      std::cout<<c<<"\n";
    }
    return 0;
  }

C++: #include<iostream>
using namespace std;

int main () {
    int a,b,x=1,count=0;
    while(cin >> a >> b,!cin.eof()){
        while(a+b>x) {
            x *=10;
            count++;
        }
     cout << count << endl;
    }
}

C++: #include<iostream>
#include<iomanip>
#include<algorithm>
#include<cmath>
#include<cstring>
#include<stack>
#include<cstdio>
#include<queue>
#define PI 3.1415927
using namespace std;
int main() {
	int a, b;
	while (cin >> a >> b) {
		int i = 1;
		int c = a + b;
		while (c / 10 > 0) {
			i++;
			c /= 10;
		}
		cout << i << endl;
	}
}

C++: #include<stdio.h>
#include<math.h>
#include<string.h>
#include<iostream>
#include<algorithm>
#include<stack>
#include<map>
#include<set>
#include<queue>
#include<vector>
#define pi 2*acos(0)
#define SF scanf
#define SFd1(a) scanf("%d",&a)
#define SFd2(a,b) scanf("%d%d",&a,&b)
#define SFd3(a,b,c) scanf("%d%d%d",&a,&b,&c)
#define PF printf
#define inf 99999999
#define eps 0.00000001
#define ll long long
#define ull long long unsigned
#define fr(i,n) for(i=0;i<n;i++)
#define dist(x1,y1,x2,y2) sqrt( ((x2-x1)*(x2-x1)) + ((y2-y1)*(y2-y1)) )
using namespace std;
//int rr[]={1,2,-1,-2,1,2,-1,-2};
//int cc[]={2,1,2,1,-2,-1,-2,-1};


main()
{
    int a,b,k;
    while(cin>>a>>b)
    {
        a+=b;
        k=0;
        while(a!=0)
        {
            a/=10;
            k++;
        }
        printf("%d\n",max(k,1));
    }
    return 0;
}

C++: #include <cstdio>
using namespace std;

int main() {
	int a,b;
	while(scanf("%d %d", &a, &b)) {
		int total=a+b,ans=1;
		while(total>10) {
			total/=10;
			++ans;
		}
		printf("%d\n",ans);
	}
}

C++: #include<iostream>
using namespace std;
int main(){
  int a,b,c;
  int d=0;
  while(cin>>a>>b){
    c=a+b;
    while(c!=0){
      c=c/10;
      d=d+1;
    }
    cout << d << endl;
  }
}

C++: #include <iostream>
using namespace std;

int main(){
	int i, j;
	while(cin >> i >> j){

		i += j;
		j = 0;

		while( i > 0, j++, i /=  10);
		cout << j;
	}
}

C++: #include <bits/stdc++.h>
using namespace std;

int main() {
    int a, b;

    for(int i = 0; i < 250; i++){
      a = 0, b = -1;
      cin >> a >> b;

      if(a + b == -1){
        break;
      }
      else{
        int digit = 0;
        int sum = a + b;
        while(sum > 0){
          sum = sum / 10;
          digit += 1;
        }
        cout << digit << endl;
      }
    }
    
}

C++: #include <iostream>
#include <math.h>

using namespace std;

int main()
{
    int a;
    int b;
    int c;

    cin >> a;
    cin >> b;

    c = ceil (log10(a+b));

    cout << c << " digit" <<endl;



    return 0;
}

C++: #include "stdio.h"

int main(){
	int a=0,b=0,c=0,count=0,i;
	for(i=0;i<=2;i++){
	scanf("%d %d",&a,&b);
	c = a + b;
	while(c > 0){
		c = c/10;
		count++;
	}
	printf("%d\n",count);
	count = 0;
	}
}

C++: #include <stdio.h>
#include<string.h>
/*
int length(const char c[])
{
    int len=0;
    while(c[len])   len++;

    return len;
}
*/
int main(void)
{
    int i=0,n=3,sum,len;
    int a,b;
    char c[10];

    scanf("%d %d",&a,&b);

    for(i=0;i<n;i++){   
        sum=a+b;
        sprintf(c,"%d",sum);
        len=strlen(c);
        printf("%d\n",len);
        scanf("%d %d",&a,&b);
    }

    return 0;

}

C++: # coding: utf-8
import sys
import math

numbers = []
for line in sys.stdin:
    numbers.append(line.split())

for i in range(len(numbers)):
    sum = int(numbers[i][0]) + int(numbers[i][1])
    print int(math.log10(float(sum))) + 1

C++: #include<stdio.h>
main(){
int x,y;
while(scanf("%d %d",&x,&y)!=EOF){
printf("%d\n",(x+y)%10);
}
}

C++: #include<iostream>
using namespace std;


int main(){

int i,d,n1,n2,sum,c;

int a,b;

while(cin >> n1 >> n2){
    if(n1 == -1 or n2 == -1)  break;
   while(n1 < 0 or n1 > 1000000 or n2 < 0 or n2 > 1000000){
      cin >> n1 >> n2;
   }
   if(n1 >= 0 and n1 <= 1000000 and n2 >= 0 and n2 <= 1000000){
       a=n1;
       b=n2;
       c=0;
       sum=a+b;
       while((sum/10)!=0){
           c++;
           sum=sum/10;
        }
       cout << c+1 << "\n";
   }
}
return 0;
}

C++: #include<iostream>
#include<cmath>
using namespace std;
int main()
{
    int a,b;
    for(int i=1;i>0;)
    {
        cin>>a>>b;
        cout<<(int)log10(a+b)+1<<endl;
    }
    return 0;
}

C++: fn main(){
    loop{
        let mut buf = String::new();
        let _ = io::stdin().read_line(&mut buf);
        if buf == "" { break; }
        let v: Vec<_> = buf.split_whitespace().collect();
        let a: i32 = v[0].parse().unwrap();
        let b: i32 = v[1].parse().unwrap();
        println!("{}", (a + b).to_string().len());
    
    }

}
    

// --- template ---
#[allow(unused_imports)]
use std::cmp::{max, min};
#[allow(unused_imports)]
 
pub trait FromLn {
    fn fromln(s: &str) -> Self;
}
pub fn readln<T: FromLn>() -> T {
    let mut buf = String::new();
    let _ = ::std::io::stdin().read_line(&mut buf).unwrap();
    T::fromln(buf.trim())
}
pub fn readlns<T: FromLn>(n: usize) -> Vec<T> {
    let mut vs = vec![];
    for _ in 0..n {
        vs.push(readln());
    }
    vs
}
macro_rules! fromln_primitives {
    ($($t:ty),*) => { $(
        impl FromLn for $t {
            fn fromln(s: &str) -> $t {
                s.parse().unwrap()
            }
        }
    )* }
}
fromln_primitives!(
    String,
    bool,
    f32,
    f64,
    isize,
    i8,
    i16,
    i32,
    i64,
    usize,
    u8,
    u16,
    u32,
    u64
);
impl<T> FromLn for Vec<T>
where
    T: FromLn,
{
    fn fromln(s: &str) -> Vec<T> {
        s.split_whitespace().map(T::fromln).collect()
    }
}
impl FromLn for Vec<char> {
    fn fromln(s: &str) -> Vec<char> {
        s.chars().collect()
    }
}
macro_rules! fromln_tuple {
    ($($t:ident),*) => {
        impl<$($t),*> FromLn for ($($t),*) where $($t: FromLn),* {
            fn fromln(s: &str) -> ($($t),*) {
                let mut it = s.split_whitespace();
                let t = ($($t::fromln(it.next().unwrap())),*);
                assert_eq!(it.next(), None);
                t
            }
        }
    }
}
fromln_tuple!(A, B);
fromln_tuple!(A, B, C);
fromln_tuple!(A, B, C, D);
fromln_tuple!(A, B, C, D, E);
fromln_tuple!(A, B, C, D, E, F);

C++: #include <iostream>
#include <string>
#include <vector>
#include <cstring>
#include <climits>
#include <algorithm>
#include <map>
using namespace std;

int main() {
    int a, b;
    while (cin >> a >> b) {
        int c = a + b;
        int res = 0;
        if (c == 0) {
            cout << 1 << endl;
            continue;
        }
        while (c) {
            c /= 10;
            res ++;
        }
        cout << res << endl;
    }
    return 0;
}

C++: using System;

class main(){
public static void Main(String[] a){
string[] s=new string[200];
for(int i;i<200;i++){
s[i]=Console.ReadLine();
}

string[] s1=new string[2];
long a,b.d,dk;

foreach(sa in s){
if(IsNullOrEmpty(sa))continue;
s1=sa.Split(' ');

a=long.Parse(s1[0]);
b=long.Parse(s1[1]);
d=a+b;
dk=(string)d.Length;
Console.WriteLine(dk);
}

}}