Go: package main

import (
	"bufio"
	"fmt"
	"os"
	"strconv"
	"strings"
	"unicode/utf8"
)

func main() {
	scanner := bufio.NewScanner(os.Stdin)
	var strs []string
	var a, b, sum int64
	var digits int
	for scanner.Scan() {
		strs = strings.Split(scanner.Text(), " ")
		a, _ = strconv.ParseInt(strs[0], 10, 64)
		b, _ = strconv.ParseInt(strs[1], 10, 64)

		sum = a + b
		// goでlen(string)はbyte数が返る
		digits = utf8.RuneCountInString(strconv.FormatInt(sum, 10))

		fmt.Printf("%d\n", digits)
	}
}

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

int main()
{
	int a,b,c;
	char str[16];
	cin >> a >>b;

	c = sprintf(str,"%d",a + b);

	cout << c << endl;
	return 0;
}

C++: #include <iostream>
#include <cmath>
int main() {
  int a, b;
  while (cin >> a >> b) {
    a = log10(a + b);
    cout << a << endl;
  }
  return 0;
}

C++: #include <iostream>

using namespace std;

int main() {
	int a[500] = { 0 }, b[500] = { 0 }, sum[500] = { 0 }, d[500] = { 0 }, k[500] = { 0 };
	int i = 0;
	while (1) {
		cin >> a[i] >> b[i];
		if (a[i] == 0 && b[i] == 0)break;
		sum[i] = a[i] + b[i];
		while (sum[i]) {
			sum[i] /= 10;
			k[i]++;
		}
		i++;
	}
	for (int j = 0; j <i;j++) {
		cout << k[j] << endl;
	}
	return 0;
}

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

#define FOR(i,l,r) for(int i = (l);i < (r);i++)
#define ALL(x) (x).begin(),(x).end()
template<typename T> bool chmax(T& a,const T& b){return a < b ? (a = b,true) : false;}
template<typename T> bool chmin(T& a,const T& b){return b < a ? (a = b,true) : false;}
typedef long long ll;

int A,B;

int digit_count(int x)
{
	int res = 0;
	do{
		res++;
	}while(x /= 10);
	return res;
}

int main()
{
	while(~scanf("%d%d",&A,&B)){
		printf("%d\n",digit_count(A + B));
	}

	return 0;
}

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

int digit_num(int num){
  int ret = 1;
  int base = 10;
  int rest = num / base;
  
  while(rest != 0){
    ret++;
    rest /= base;
  }
  
  return ret;
}

int main(){
  while(!cin.eof()){
    int a, b;
    cin >> a;
    cin >> b;

    int c = a + b;
    cout << digit_num(c) << endl;
  }

  return 0;
}

C++: #include <iostream>

using namespace std;

int main() {
	int a, b;
	string s;
	while (cin >> a >> b) {
		s = to_string(a+b);
		cout << s.size() << endl;
	}
	return 0;
}

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

int main()
{
	int a,b,sum;
	int count = 1;
	
	cin >> a >> b;

	sum = a + b;

	sum = sum / 10;

	while(sum >= 1){

		sum = sum / 10;
		count++;
	}

	cout << count << endl;
	cin >> a;
	

	return 0;
}

C++: // ------------------------------------
// Date:2018/ 2/11
// Problem:0002 : DigitNumber 2.cpp
//
// ------------------------------------

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

#define FOR(i,a,b) for(int i=(int)a;i<(int)b;++i)
#define REP(i,n) FOR(i,0,n)

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

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

int number_of_digits(int n) {
	int result = 0;
	while (n != 0) {
		result++;
		n /= 10;
	}
	return result;
}

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

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

C++: #include<stdio.h>

int main(){
    int a,b,sum,i;
    while(scant("%d %d",a,b)!=-1){
        sum=a+b;
        for(i=0;sum!=0;i++){
            sum=sum/10;
        } 
        printf("%d\n",i);
     }
    
    return 0;
}

C++: #include <stdio.h>
#include <string.h>
#include <stdlib.h>

int main()
{
    int IsB = 0,i = 0;
    char a[100],b[100],*digits;
    while(1){
        char str = '\0';
        scanf("%c",&str);
        if(str == '\0')break;
        if(str == ' '){
            i = 0;
            IsB = 1;
        }else if(str == '\n'){
            sprintf(digits,"%d",atoi(a) + atoi(b));
            printf("%d\n",strlen(digits));
            i = 0;
            IsB = 0;
        }else if(IsB == 0){
            a[i++] = str;
        }else{
            b[i++] = str;
        }
    }
}

C++: #include<stdio.h>
#include<iostream>
using namespace std;
int main()
{
	int a,b,sum,i,k[100];
	while(scanf("%d%d",&a,&b)!=EOF)
	{
		sum=a+b;
		i=0;
		while(sum)
		{
			sum/=10;
			i++;
		}
		printf("%d\n",a);

	}
	return 0;
}

C++: #include <iostream>
#include <cmath>
#include <array>

template<class T>
T input()
{
	T val;
	std::cin >> val;
	return val;
}

int main()
{
	std::array<int, 200> hoge;
	for (int i = 0; i < 200; ++i)
		hoge[i] = input<int>() + input<int>();

	for (int i = 0; i < 200; ++i)
		std::cout << static_cast<int>(log10(hoge[i])) + 1 << std::endl;
	return 0;
}

C++: #include <list>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <vector>

template<class T> inline string toString(T x) { ostringstream sout; sout << x; return sout.str(); }
using namespace std;
int main()
{
	int a, b;
	while (cin>>a>>b)
	{
		cout << to_string(a+b).length() << endl;
	}
	return 0;

}

C++: import java.io.*;

class Main {
	public static void main(String args[]) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String s[], t;
			int i, j, ans, l, m;
			boolean flag = false;
			while((t = reader.readLine()) != null) {
				s = t.split(" ");
				i = s[0].length()-1 >= s[1].length()-1 ? s[0].length()-1 : s[1].length()-1;
				j = s[0].length()-1 <= s[1].length()-1 ? s[0].length()-1 : s[1].length()-1;
				l = s[0].length()-1 >= s[1].length()-1 ? 0 : 1;
				int a[][] = {new int[i+1], new int[j+1]};
				for(int k = 0;k < i+1;k++) {
					a[0][k] = s[l].charAt(k)-'0';
				}
				int f = Math.abs(l-1);
				for(int k = 0;k < j+1;k++) {
					a[1][k] = s[f].charAt(k)-'0';
				}
				while(i>=0) {
					if(j >= 0)
						m = a[1][j];
					else
						m = 0;
					a[0][i] = a[0][i] + m;
					if(a[0][i]>9) {
						if(i>0) {
							a[0][i] %= 10; 
							a[0][i-1]++;
						}
						else if(i==0){
							flag = true;
							break;
						}
					}
					i--;
					j--;
				}
				ans = flag ? a[0].length+1 : a[0].length;
				System.out.println(ans);
				flag = false;
			}
		}
		catch(IOException e) {
			System.out.println(e);
		}
	}
}

C++: #include <iostream>

int main() {
	using namespace std;

	for (;;) {
		int a, b;
		cin >> a >> b;
		if (cin.eof()) { break; }

		int sum = a + b;
		int num = 0;
		for (; sum != 0; ++num) {
			sum /= 10;
		}

		cout << num << endl;
	}
	return 0;
}

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

using namespace std;

int main(void){
	long	a,b;

	for(int i=0;i<200;i++){
		cin >> a;
		cin >> b;

		cout << (int)log10(a+b)+1 << endl;
	}

	return 0;
}

C++: #include <bits/stdc++.h>
using namespace std;
int a, b;
int main() {
	while(cin >> a >> b) {
		if(a || b) cout << to_string(a + b).size() << endl;
	}
}

C++: #include<iostream>
using namespace std;
int main()
{
int a,b;
while(cin>>a>>b)
{
cin>>a>>b;

if(a+b<10)
{
	cout<<1<<endl;
}
else if(a+b<100)
{
	cout<<2<<endl;
}
else if(a+b<1000)
{
	cout<<3<<endl;
}
else if(a+b<10000)
{
	cout<<4<<endl;
}
else if(a+b<100000)
{
	cout<<5<<endl;
}
else if(a+b<1000000) 
{
	cout<<6<<endl;
}
else if(a+b<10000000)
{
	cout<<7<<endl;
}
}
return 0;
}