Go: package main

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

func main() {
	scanner := bufio.NewScanner(os.Stdin)
	for scanner.Scan() {
		i := scanner.Text()
		var total int
		inputNum := strings.Fields(i)
		for _, v := range inputNum {
			num, err := strconv.Atoi(v)
			if err != nil {
				break
			}
			total += num
		}
		fmt.Println(DigitCount(strconv.Itoa(total)))
	}
}

func DigitCount(str string) int {
	return len(str)
}

C++: //
//  main.cpp
//  Sample
//
//  Created by h3037183 on 2017/07/31.
//  Copyright ?? 2017??´ ?°????. All rights reserved.
//

#include <iostream>
#include<algorithm>
using namespace std;
int main(){
    long a,b,i=0,sum=0;
    while(cin>>a>>b){
    sum=a+b;
    if(sum==1000000)i=7;
    else if(sum>99999)i=6;
    else if(sum>9999)i=5;
    else if(sum>999)i=4;
    else if(sum>99)i=3;
    else if(sum>9)i=2;
    else i=1;
    cout<<i<<endl;
        i=0;
    }
    return 0;
}

C++: #include <cstdio>

int main()
{
        unsigned int a, b, sum;
        unsigned int digit;

        while (scanf("%u %u", &a, &b) != EOF) {
                sum = a + b;
                digit = 0;
                while (sum) {
                        sum /= 10;
                        digit++;
                }
                printf("%u\n", digit);
        }

        return 0;
}

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

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

int main(){
	double a_heap[3];
	double b_heap[3];
	int digit[3];
	int count;
	for(int i=0;i<3;i++){
		cin >> a_heap[i] >> b_heap[i];
		cout << endl;
	}
	for(int i=0;i<3;i++){
		int num1 = 1;
		int j;
		for(j=1;;j++){
			num1 = 10 * num1;
		if((a_heap[i] + b_heap[i])/num1 < 1)
			break;
		}
		digit[i] = j;
	}
	for(int i=0;i<3;i++){
	cout << digit[i] << endl;
	}
	return 0;
}

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

int unsignedGeddigit(int a){
	return log10(a)+1;
}

int main(){
	int a,b,x[200],i=0;
	while(cin>>a>>b){
	x[i]=unsignedGeddigit(a)+unsignedGeddigit(b);
	i++;
	}
	for(int j=0;j<i;j++){
		cout<<x[j]<<endl;
	}

	return 0;
}

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

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

#include <iostream>
#include <algorithm>
using namespace std;
int main(){
    int i,o;
    for(int p=0;p<200;p++){
    cin>>i>>o;
    if(i+o<10){
        cout<<"1"<<endl;
    }else if(i+o<100){
        cout<<"2"<<endl;
    }else if(i+o<1000){
        cout<<"3"<<endl;
    }else if(i+o<10000){
        cout<<"4"<<endl;
    }else if(i+o<100000){
        cout<<"5"<<endl;
    }else if(i+o<1000000){
        cout<<"6"<<endl;
    }else if(i+o<10000000){
        cout<<"7"<<endl;
    }else{
        break;
    }
    }
}

C++: #include <iostream>

using namespace std;

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

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

int main(void){
    int a, b;
    while(cin >> a >> b){
        cout << to_string(a + b).size() << endl;
    }
}

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

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

C++: #include<stdio.h>
int main(void)
{
	int dec1[3],dec2[3],sum[3],keta[3]={0,0,0};
	for(int f1=0;f1<3;f1++){
		scanf("%d %d",&dec1[f1],&dec2[f1]);
		sum[f1]=dec1[f1]+dec2[f1];
	}
	for(int f1=0;f1<3;f1++){
		while(sum[f1]>=10){
			sum[f1]=sum[f1]/10;
			keta[f1]++;
		}
	}
	for(int f1=0;f1<3;f1++){
		printf("%d\n",keta[f1]+1);
	}
	return 0;
}

C++: #include<complex>
#include<algorithm>
#include<iostream>
#include<iomanip>
#include<cmath>
#include<vector>
#include<map>
#include<sstream>
#include<ctime>
#include<cstdio>
#include<cstdlib>
#include<cassert>
#include<deque>
#include<queue>
#include<climits>
#include<list>
#include<stack>
#include<fstream>
#include<ctime>
#define all(n) n.begin(),n.end()
#define REP(i,s,n) for(int i=s;i<n;i++)
#define rep(i,n) REP(i,0,n)
#define insert(a,b,c,d) PP(P(a,b),P(c,d))
#define F first
#define S second
#define pb push_back
#define INF (1<<27)
#define EPS 1e-10
#define equals(a,b) (fabs((a)-(b)) < EPS)

using namespace std;

typedef pair<int,int> P;
typedef pair<P,P> PP;
typedef unsigned long long ull;
typedef long long ll;
const int dx[4] = {0,1,0,-1};
const int dy[4] = {1,0,-1,0};


int main(){

  int a,b;
  while(cin >> a >> b){
    int c = a+b;
    stringstream ss;
    ss << c;
    string ret;
    ss >> ret;   
    cout << ret.size() << endl;
  }

  for(int j=0;j<=100000;j++){
    string name = "out";
    stringstream ss;
    ss << j;
    string index;
    ss >> index;
    name += index+".txt";
    ofstream ofs(name.c_str());
      ofs << string(100000,'?') << endl;
    
  }

return 0;
}

C++: #include <bits/stdc++.h>
#define forn(x, n)              for (int x = 0; x < n; x++)
#define forr(x, n)              for (int x = n; x >= 0; x--)
#define fore(x, a, b, c)        for (int x = a; x <= b; x += c)
#define forre(x, a, b, c)       for (int x = a; x >= b; x -= c)
#define clr                     cin.ignore(numeric_limits<streamsize>::max(), '\n')
#define all(container)          (container).begin(), (container).end()
#define rall(container)         (container).rbegin(), (container).rend()
#define FILL(x, val)            memset(x, val, sizeof(x))
#define sz(container)           ((int) (container).size())
#define pb                      push_back
#define eb                      emplace_back
#define fi                      first
#define se                      second
#define mod                     (ll)1000000007
#define INF                     (int)0x3f3f3f3f

using namespace std;

#ifdef LOCAL_DEFINE
    #include "../../CLionProjects/Codeforces/library/DEBUG.hpp"
#endif

template<class T> bool uin(T &a, T b) { return a > b ? (a = b, true) : false; }
template<class T> bool uax(T &a, T b) { return a < b ? (a = b, true) : false; }
int MAX() {return -INF;}
int MIN() {return INF;}
template<typename T, typename... Args>
T MAX(T a, Args... args) {return max(a, MAX(args...));}
template<typename T, typename... Args>
T MIN(T a, Args... args) {return min(a, MIN(args...));}

typedef long long ll; 
typedef vector<bool> vb;
typedef vector<vector<int>> vvi;
typedef vector<int> vi;
typedef vector<long long> vll;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
typedef vector<pair<int, int>> vpii;
typedef vector<pair<long long, long long>> vpll;


int main(void) {    
#ifdef LOCAL_DEFINE
    freopen("in.txt", "r", stdin);
#endif
    
    int a, b;
    while (scanf("%d %d", &a, &b) == 2) {
        int num = a + b, ans = 0;
        while (num) {
            ++ans;
            num /= 10;
        }
        printf("%d\n", ans);
    }

#ifdef LOCAL_DEFINE
    cerr << "Time elapsed : " << 1.0 * clock() / CLOCKS_PER_SEC << '\n';
#endif
    return 0;
}

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

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