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(){
	int a;
	int b;
	int sum;

	while (cin >> a >> b){
		sum = a + b;
		if (sum < 10){
			cout << 1 << endl;
		}
		else if (sum > 10 && sum < 100){
			cout << 2 << endl;
		}
		else if (sum < 1000 && 100 < sum){
			cout << 3 << endl;
		}
		else if (sum < 10000 && 1000 < sum){
			cout << 4 << endl;
		}
		else if (sum < 100000 && 10000 < sum){
			cout << 5 << endl;
		}
		else if (sum < 1000000 && 100000 < sum){
			cout << 6 << endl;
		}
		else if (sum < 10000000 && 1000000 < sum){
			cout << 7 << endl;
		}
		else if (sum < 100000000 && 10000000 < sum){
			cout << 8 << endl;
		}
	}

	return 0;
}

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

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

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

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

C++: //
//  main.cpp
//  b
//
//  Created by h3037178 on 2017/07/31.
//  Copyright ?? 2017??´ ?????£?????????. All rights reserved.
//

#include <iostream>
#include <algorithm>
using namespace std;
int main(){
    int i,o,b=0;
    for(int p=0;p<200;p++){
        cin>>i>>o;
        b=0;
        if(i+o==0){
            break;
        }
        for(int j=1;j<=1000000;j=j*10){
            if(i+o>=j){
                b++;
            }else{
                break;
            }
        }
        cout<<b<<endl;
        }
}

C++: #include <iostream>
using namespace std;
int main(void){
    int a,b,c;
    while (cin >>a>>b){
    
    c=a+b;
    
    if(c<10) cout << "1" <<endl;
    else if (c<100) cout << "2" <<endl;
    else if (c<1000) cout << "3" <<endl;
    else if (c<10000) cout <<"4" <<endl;
    else if (c<100000) cout<<"5" <<endl;
    else if (c<1000000) cout <<"6"<<endl;
    else cout <<"7" <<endl;
    
    }
    
}

C++: #include<bits/stdc++.h>
#define rep(i,n) for(int i=0;i<n;i++)
using namespace std;
int main(){
 int a,b;
 while( cin >> a >> b ){
  int x = a+b;
  int cnt = 0;
  while(x>0){
   x/=10; 
   cnt++;
  }
  cout << cnt << endl;
 }
 return 0;
}

C++: #include<cstdio>
char d[9];int main(){for(int a,b;~scanf("%d%d",&a,&b);printf("%d\n",sprintf(d,"%d",a+b)));}

C++: #include<iostream>
#include<string>
using namespace std;
int main(){
	int a,b;
	while(true){
	cin>>a>>b;
	if(a==-1||b==-1)
		break;
	int i=0;
	int h=a+b;
	while(true){
		if(0==h)
			break;
		i++;
		h/=10;
	}
	cout<<i<<endl;
	}
	return 0;
}

C++: import java.util.Scanner;

class Main{

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        for (int i = 0; i < 200; i++) {
            int sum;
            int[] n = new int[2];
            n[0] = sc.nextInt();
            n[1] = sc.nextInt();
            sum = n[0] + n[1];
            String s;
            s = String.valueOf(sum);
            System.out.println(s.length());
        }

    }
}

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

#ifndef EOF
#define EOF (-1)
#endif

int main() {
    std::vector<int> digits;
    int a, b;
    while (scanf("%d %d", &a, &b) != EOF)
    {
        int sum = a + b;
        int t = sum / 10;
        int digit = 0;
        while (t > 0) {
            digit ++;
            t = t / 10;
        }
        digits.push_back(digit);
    }

    for (int i = 0; i < digits.size(); i++) {
        std::cout << digits[i] << std::endl;
    }

    return 0;
}

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

int main(){
	int a,b,c;
	int ans;
	
	string cunning="776757";
	
	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 <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;
      }
    }
    
}