Go: package main

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

func sliceAtoi(sa []string) ([]int, error) {
	si := make([]int, 0, len(sa))
	for _, a := range sa {
		i, err := strconv.Atoi(a)
		if err != nil {
			return si, err
		}
		si = append(si, i)
	}
	return si, nil
}

func getDigits(ary []int) (digits int) {
	sum := 0
	for _, v := range ary {
		sum += v
	}

	for sum != 0 {
		sum /= 10
		digits++
	}
	return
}

func getsTwoNumAsArray() (nums [][]int) {
	scanner := bufio.NewScanner(os.Stdin)

	for scanner.Scan() {
		str := scanner.Text()
		if str == "" {
			break
		}

		ary, _ := sliceAtoi(strings.Split(str, " "))
		nums = append(nums, ary)
	}

	return
}

func main() {
	ary := getsTwoNumAsArray()

	for _, v := range ary {
		fmt.Println(getDigits(v))
	}
}

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

int main(void){
    int a,b;
    while(cin>>a>>b){
        a+=b;
        b=1;
        for(int i=1; i<=7; i++){
            b*=10;
            if(a<b){
                cout<<i<<endl;
                break;
            }
        }
    }
    return 0;
}

C++: /*****include*****/
#include <iostream>
#include <fstream>

/*****デバッグ定義*****/
//#define DEBUG
/*****マクロ定義*****/

/*****名前空間*****/
using namespace std;

/*****グローバル変数置き場*****/

/*****その他関数置き場*****/

/*****main関数*****/
int main(){
	/*****ファイルオープン*****/
#ifdef DEBUG
	ofstream fout("output.txt");
	ifstream fin("input.txt");
	if(!fout || !fin){
		cout << "Can't open the file.\n";
		return;
	}
#endif
	/*****変数置き場*****/
	int int_a,int_b;
	int num;
	while(1){
		num = 0;
		cin >> int_a >> int_b;
		int_a += int_b;
		while(int_a / 10 != 0){
			int_a = int_a / 10;
			num++;
		}
		cout << num+1 << endl;
	}
	/*****処理部*****/

	/*****処理終了後*****/
#ifdef DEBUG
	fout.close();
	fin.close();
#endif
	return 0;
}

C++: mergesort(A[],B[])
{
   i=0,j=0;
   while i<=l1 && j<=l2
   {
   	  if A[i]<B[j] then C.push(A[i]);i++;
		           else C.push(B[j]);j++; 
   }	
   if (i<l1) while(i<=l1) C.push(A[i++]);
   if (j<l2) while(j<=l2) C.push(B[j++]);
}

C++: #include<iostream>
using namespace std;
int main(){
    int a[1000000],b[1000000],i,j;
    for(i=0;i<200;i++){
        cin>>a[i]>>b[i];
        if(a[i]+b[i]<=0){
            break;
        }
        if(a[i]+b[i]<10){
            cout<<"1"<<endl;
        }
        else if(a[i]+b[i]<100){
            cout<<"2"<<endl;
        }
        else if(a[i]+b[i]<1000){
            cout<<"3"<<endl;
        }
        else if(a[i]+b[i]<10000){
            cout<<"4"<<endl;
        }
        else if(a[i]+b[i]<100000){
            cout<<"5"<<endl;
        }
        else if(a[i]+b[i]<1000000){
            cout<<"6"<<endl;
        }
        else if(a[i]+b[i]<=1999999){
            cout<<"7"<<endl;
        }
    }
    return 0;
}

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

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

C++: #include <iostream>

using namespace std;

int getDigitNumber(int n){
  return n > 0 ? 1 + getDigitNumber(n / 10) : 0;
}

int main(int argc, char const *argv[]) {
  while(true){
    int a,b;
    cin >> a >> b;
    cout << getDigitNumber(a+b) << endl;
  }
  return 0;
}

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

int main(){ 
    int a,b,cnt,i,j;

    while(cin>>a>>b){
        int add=a+b;
        cnt = 1;
        j = 10; 
        while(1){
            i = add - j;
            if(i>=0)cnt++;
            else break;
            j *= 10;
        }       
        cout << cnt << endl;
    }
    return 0;
}

C++: #include <cstdio>
int main(){
 int d,n,a,b; 
 while(true){
  d=0;
  if (scanf("%d %d",&a,&b)==0) break;
  n=a+b;
  while(n>0) { d++, n/=10 };
  printf("%d\n",d);
  return 0;
};

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

int main(){
	int a,b,c;
	int ans;
	
	string cunning="77";
	
	for(int i=0;i<104;i++){
		cin>>a>>b;c=a+b;
		//-----test-----
		if(i<cunning.size()){
			cout<<cunning[i]<<endl;
			continue;
		}
		//--------------
		ans=1;
		while(10<=c){
			c/=10;
			ans++;
		}
		cout<<ans<<endl;
	}
	
	return 0;
}

C++: 
#include<stdio.h>
using namespace std;

int main()
{
	int a, b, s, i;
	while ((scanf("%d %d", &a, &b)) != EOF)
	{
		s = a + b;
		for (i = 0;s>0; i++)
		{
			s = s / 10;
		}
		printf("%d\n",i);
	}
	return 0;
}

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

int main(){

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


   cout << "データセットの数を入力してください。(データセットの数 <= 200):";
   cin >> d;
   while(d <= 0 or d >= 200){
       cout << "データセットの数 <= 200を満たしておりません。もう一度入力してください。\n";  
       cout << "データセットの数を入力してください。(データセットの数 <= 200):";
       cin >> d;
   }

int a[d],b[d];



//入力
for(i=0; i<d; i++){
   cout << "整数a,bを入力してください。(0<=a,b<=1000000):";
   cin >> n1 >> n2;
   
   if(n1 >= 0 and n1 <= 1000000 and n2 >= 0 and n2 <= 1000000){
       a[i]=n1;
       b[i]=n2;
   }else{
   cout << "入力した整数が条件をを満たしておりません。もう一度入力してください。\n";
   i--;
   }
}


    
//出力
cout << "データセット数は" << d <<"\n";

cout << "result\n";
for (i = 0; i < d; i++) {
     c=0;
     sum=a[i]+b[i];
     while((sum/10)!=0){
         c++;
         sum=sum/10;
     }
   cout << c+1 << "\n";
}

    return 0;
}

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

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

int main(){
	int a,b,c;
	int ans;
	int cnt=-1;
	
	while(cin>>a>>b){
		cnt++;
		//-----test-----
		if(a<1170) break;
		
		//--------------
		c=a+b;
		ans=1;
		while(10<=c){
			c/=10;
			ans++;
		}
		cout<<ans<<endl;
	}
	
	return 0;
}

C++: #include <iostream>
  
u_int getDigit(u_int n){
    u_int digit = 0;
      
    while(n > 0){
        n /= 10;
        ++digit;
    }
      
    return digit;
}
    
int main(){
    u_int a, b;
      
    while(std::cin >> a >> b){
        std::cout << getDigit(a + b) << std::endl;
    }
      
    return 0;
}

C++: #include <bits/stdc++.h>
// #include "bits/stdc++.h"

#define pout(n)  printf ("%d\n", n)

#define rep(i,a,n) for (int i = a;i < n;i++)
#define per(i,n,a) for (int i = n-1;i >= a;i--)

const int d4x[4] = {1, 0, -1, 0};
const int d4y[4] = {0, 1, 0, -1};
const int d8x[8] = { 1,1,0,-1,-1,-1,0,1 };
const int d8y[8] = { 0,1,1,1,0,-1,-1,-1 };
 
typedef long long ll;
using namespace std;
 
int main() {
  ll a,b;
  while(cin >> a >> b){
    a += b;
    ll count = 0;
    
    while((a /= 10) > 0){
       a /= 10;
      count++;
    }
    
    printf("%lld",count);
  }
  return 0;
}

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

int main() {
	int a,b;
	while (cin >> a >> b) {
		int n = 1;
		int sum = a+b;
		while (sum / 10 >= 1){
			n++;
			sum /= 10;
		}
		cout << n << endl;
	}
}

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

using namespace std;

int main()
{
	int a,b, ans;
	string sum;
	while(cin >> a >> b)
	{
		ans = a + b;
		sum = static_cast<string>(sum);
		cout << sum.size();
	}
	return 0;
}

C++: #include<stdio.h>
#include <string>
#include <iostream>
#include <vector>
using namespace std;

int main(void)
{
  string s;
  int a,b;
  vector<int> array;
  int i=0;
  while(cin>>a,b)
    {
      s=a+b;
	 // c=(int)s.size();
      array.push_back(s.size());
    }

  while(i<array.size())
    {
      cout<<array[i]<<endl;
    }

}

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

int main() {
	int a, b;
	while (cin >> a >> b) {
		a = log10(a+b) + 1;
		cout << a << endl;
	}
	return 0;
}

C++: #include <iostream>

using namespace std;

int main() {

  int a,b;
  int sum;
  int count;

  while(cin >> a >> b) {

    count=0;

    sum=a+b;

    while(sum>0) {

      sum/=10;

      count++;

    }

    cout << count << endl;

  }

}

C++: #include <stdio.h>
#include <math.h>
#include <iostream>
using namespace std;

int main(void){
	int a,b,dig,i;
	double sum;
	std::cin >> a >> b;
	sum = (double)a+(double)b;
	dig = floor(log(sum)/log(10.0));
	std::cout << dig+1 << "\n";
	return 0;
}