Go: package main

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

func main() {
        sc := bufio.NewScanner(os.Stdin)

        for sc.Scan() {
                digits := 0
                num := 0
                for _, s := range strings.Fields(sc.Text()) {
                        i, _ := strconv.Atoi(s)
                        num += i
                }
                for num > 0 {
                        digits += 1
                        num /= 10
                }
                fmt.Printf("%d\n", digits)
        }
}

C++: #include<iostream>
int main(){
	int d=200;
	while(d>0){
		int a,b;
		std::cin>>a>>b;
		int n=a+b;
		if(n<10)std::cout<<1<<std::endl;
		if(n>=10&&n<100)std::cout<<2<<std::endl;
		if(n>=100&&n<1000)std::cout<<3<<std::endl;
		if(n>=1000&&n<10000)std::cout<<4<<std::endl;
		if(n>=10000&&n<100000)std::cout<<5<<std::endl;
		if(n>=100000&&n<1000000)std::cout<<6<<std::endl;
		if(n>=1000000&&n<10000000)std::cout<<7<<std::endl;
	}
	return 0;
}

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

int main(void)
{
	int sum = 0;
	char a;

	while(1){
		sum = 0;
		while(scanf("%c", &a), a != ' ')
			sum++;
		while(scanf("%c", &a), a != '\n')
			sum++;
		printf("%d\n", sum);

	}

	return 0;
}

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

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

int main() {
	// your code goes here
	int a,b;
	while (cin >> a >> b) {
		
		int wa = a + b;
		//判定開始
		int ans = 1;
		while(1) {
			wa = wa/10;
			ans++;
			if (wa<10) break;
		}
		cout << ans << endl;
	}
	return 0;
}

C++: #include<iostream>
using namespace std;
int get_dig(int a){
	int i;
	for(i=0;a>0;i++){
		a=a/10;
	}
	return i;
}

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

C++: #include<iostream>
#include<iomanip>
#include<cstdio>
#include<cmath>
#include<cstring>
#include<cstdlib>
#include<string>
#include<cctype>
#include<vector>
#include<set>
#include<map>
#include<stack>
#include<queue>
#include<deque>
#include<list>
#include<algorithm>
using namespace std;

#define LL long long
#define LLU unsigned long long
#define re return(0)
#define pi 2*acos(0.0)

const int infinity=100000000000;

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

C++: #include <iostream>
#include <stdio.h>
#include <vector>
#include <algorithm>

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

using namespace std;

int main(void){
    
    int number1,number2;
    int counter = 0;
    while(scanf("%d %d",&number1,&number2) != EOF)
    {
        cout << (((number1+number2) /10))+1 << endl;
    }

    return 0;


}

C++: #include <iostream>
#include <algorithm>
#include <vector>
#include <string>
#include <sstream>
#include <fstream>

using namespace std;

int add (string a, string b)
{
	reverse (a.begin(), a.end() );
	reverse (b.begin(), b.end() );

	while (a.length() != b.length()){
		if (a.length() > b.length()){
			b += '0';
		}else if (a.length() < b.length() ){
			a += '0';
		} // end if
	} // end while

	int i;
	string res = "";
	int carry = 0;

	for (i = 0; i < a.length(); ++i){

		int an = a[i] - '0';
		int bn = b[i] - '0';
		int sum = an + bn + carry;

		res += sum % 10 + '0';
		carry = sum/10;

	} // end for

	if (carry == 1){
		res += carry + '0';
	} // end if

	return res.length();
}

int main()
{
	string str = "";
	string a,b;

	while (getline (cin, str )){

		stringstream ssn(str );
		ssn >> a >> b;

		int res = add (a, b );

		cout << res << endl;	

	} // end while
		
	return 0;
}

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

double* solve_equations(int *a)
{
	// クラメルの公式を用いる
	int data_size=sizeof(a[0]);
	/*cout << "data_size=" << data_size << endl;
	cout << "a=" << a << endl;
	cout << "*(a + data_size*1)=" << *(a + 1) << endl;
	cout << "*(a + data_size*0) * *(a + data_size*4)" << *(a + data_size*0) * *(a + data_size*4) << endl; */
	int z = *(a + 0) * *(a + 4) 
		  - *(a + 1) * *(a + 3);
	int x = *(a + 2) * *(a + 4)
		  -	*(a + 1) * *(a + 5);
	int y = *(a + 0) * *(a + 5)
		  - *(a + 2) * *(a + 3);  
	double ax,ay;
	/*cout << "x=" << x << endl;
	cout << "y=" << y << endl;*/
	ax = pow(z,-1)*x;
	ay = pow(z,-1)*y;
	
	/* cout << ax << endl;
	cout << ay << endl; */
	double ans[2] = {ax,ay};
	return ans;
}

int main()
{
	int n[6];
	int s;
	int i=0;
	while (cin >> s){
		if (i == 5){
			n[i]=s;
			for (int j=0;j<=5;j++)
			{
				cout << "n[" << j << "]=" << n[j] << endl;
			}
			double* an;
			an = solve_equations(n);
			/* printf("%.3lf",*(an+0));
			cout << " " << endl;
			printf("%.3lf",*(an+1)); */
			cout << fixed << setprecision(3) << an[1] << " " << an[0] << endl;

			i = 0;}
		else{
			n[i]=s;
			i++;
		}
	}
	return 0;
			// cout << l[0]  endl;
}

C++: #include<iostream>

using namespace std;

int main(){
  int cnt = 1,
      x, y;
  while(cin >> x >> y){
    if(cin.eof())
      break;
    if(x < 0 || y > 1000000 || cnt > 200)
      break;
    cnt++;
    cout << cnt << endl;
  }
}

C++: #include<iostream>
using namespace std;
int main(){
int a,b;
char c[10];
cin>>a>>b;
a+=b;
c[]=(char)a;
for(int i=0;c[i]!='\0';i++)

cout<<i+1<<endl;
}

C++: #include<stdio.h>
#include<math.h>
#include<stdlib.h>
#include<string.h>
#include<string>
#include<algorithm>
#include<iostream>
#include<stack>
#include<queue>
#include<vector>
#include<map>
#include<set>
using namespace std;
int reshan(int sum)
{
    int i=0;
    while(sum!=0)
    {
        i++;
        sum=sum/10;
    }
    return i;5
}
int main ()
{
    int in1,in2;
    int i;
    while (scanf ("%d %d",&in1,&in2)!=EOF)
    {
        int sum=in1+in2;
        int z=reshan(sum);
        printf ("%d\n",z);
    }
    return 0;
}

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

int main(){
	int a, b;
	list<int> digit;
	
	while(!(cin>>a>>b).eof()){
		if((a+b)>0){
			int c=a+b;
			stringstream ss;
			ss << c;
			digit.push_back(ss.str().size());
		}
		
	}
	list<int>::iterator it = digit.begin();
	while(it != digit.end()){
		cout << *it << endl;
		it++;		
	}
	
 	return 0;
}

C++: #include<iostream>
#include<algorithm>
using namespace std;
int main(){
	int a,b;
	while(cin>>a>>b){
	int t=8750;
	for(int i=t;i;i--){
		for(int j=i;j;j--){
			if(i+j==2)a+=b;
		}
	}
	int cnt=0;
	while(a)a/=10,cnt++;
	cout<<cnt<<endl;
	}
	return 0;
}

C++: #include<stdio.h>
int main(void)
{
	int a,b,s;
	scanf("%d %d",&a,&b);
	s=a+b;
	if(s<10){
		printf("1\n");
	}
	else if(s>9&&s<100){
		printf("2\n");
	}
	else if(s>99&&s<1000){
		printf("3\n");
	}
	else if(s>999&&s<10000){
		printf("4\n");
	}
	else if(s>9999&&s<100000){
		printf("5\n");
	}
	else if(s>999999&&s<1000000){
		printf("6\n");
	}
	else{
		printf("7\n");
	}
	return 0;
}

C++: #include <iostream>
#define  N 3

int main()
{
	int a[N]={-1}, b[N]={-1}, num[N],answer[N] = {-1};

	for(int i=0; i<N; ++i)
	{
		std::cin >> a[i] >> b[i];

		num[i] = a[i] + b[i];

		if(num[i] < 10)
		{
			answer[i] = 1;
		}

		else if(num[i] < 100)
		{
			answer[i] = 2;
		}

		else if(num[i] < 1000)
		{
			answer[i] = 3;
		}

		else if(num[i] < 10000)
		{
			answer[i] = 4;
		}

		else if(num[i] < 100000)
		{
			answer[i] = 5;
		}

		else if(num[i] < 1000000)
		{
			answer[i] = 6;
		}

		else
		{
			answer[i] = 7;
		}
	
	}

	for(int j=0; j<N; ++j)
	{
		std::cout << answer[j] << '\n';
	}
	
}