Go: package main

import (
	"bufio"
	"fmt"
	"math/big"
	"os"
	"strconv"
)

var sc = bufio.NewScanner(os.Stdin)

func main() {
	sc.Scan()
	dataset, _ := strconv.Atoi(sc.Text())
	var firstdata *big.Int

	for i := 0; i < dataset*2; i++ {
		n := new(big.Int)
		sc.Scan()
		data, _ := n.SetString(sc.Text(), 10)

		if i%2 == 0 {
			firstdata = data
			continue
		}

		result := new(big.Int)
		if result := result.Add(data, firstdata); len(result.String()) > 80 {
			fmt.Println("overflow")
			continue
		} else {
			fmt.Println(result)
		}
	}
}

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

struct Integer{
    int num[100];
    Integer(const char *s){
        fill_n(num,100,0);
        int l=strlen(s);
        for(int i=0;i<l;i++){
            num[l-i-1]=s[i]-'0';
        }
    }
};
const Integer operator+(const Integer &lint,const Integer &rint){
    Integer ret("");
    for(int i=0;i<100;i++){
        int v=ret.num[i]+lint.num[i]+rint.num[i];
        ret.num[i]=v%10;
        if(i+1>=100)continue;
        ret.num[i+1]+=v/10;

    }
    return ret;
}

char a[100],b[100];
int main(){
    int n;
    scanf("%d",&n);
    while(n--){
        scanf("%s%s",a,b);
        Integer ans=Integer(a)+Integer(b);
        int s=0;
        for(int i=0;i<100;i++)if(ans.num[i])s=i;
        if(s-1>=80){
            puts("overflow");
            continue;
        }
        for(int i=s;i>=0;i--)printf("%d",ans.num[i]);
        puts("");
    }
    return 0;
}

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

using namespace std;

int main(){
	
    string s1, s2;
    int n;
    
    cin >> n;
    
    while( n-- ) {
    	
	cin >> s1 >> s2;
	
	if( s1.length() > 80 || s2.length() > 80)
  	cout << "overflow\n";
  	
  	else {
  	
  	int i1 = s1.length();
  	int i2 = s2.length();
  	
  	string ans;
    int tmp = 0;
    int up = 0;
  	
  	while( i1 > 0 && i2 > 0 ) {
  		
  		tmp = (s1[i1 - 1] + s2[i2 - 1]) - 2 * '0' + up;
  		
        up = tmp / 10;
        tmp %= 10;
        ans = char(tmp + '0') + ans;
  	
  		i1--;
  		i2--;
  		
	  }
	  if (i1 > 0) {
        while( i1 > 0  ) {
            tmp = s1[i1 - 1] - '0' + up;
            
            up = tmp / 10;
            tmp %= 10;
            ans = char(tmp + '0') + ans;
            
            i1--;
        }
    }
        else if (i2 > 0) {
            while( i2 > 0  ) {
            tmp = s2[i2 - 1] - '0' + up;
                
            up = tmp / 10;
            tmp %= 10;
            ans = char(tmp + '0') + ans;
                
            i2--;
        }
    }
 
        if (up > 0)
        ans = char(up + '0') + ans;
 
        if (ans.size() > 80)
        cout << "overflow" << endl;
        
        else
        cout << ans << endl;
  }
}
  return 0;
}

C++: #define _CRT_SECURE_NO_WARNINGS
#define M_PI 3.14159265358979
#include <iostream>
#include <stdio.h>
#include <string>
#include <math.h>
#include<iomanip>
#include<vector>
#include<cmath>
#include <algorithm>
#include <cstdlib>
#include <typeinfo>
using namespace std;



int main(){
	int n;
	string x, y;
	int a, b, c;
	cin >> n;
	for (int i = 0; i < n; i++)
	{
		cin >> x >> y;
		if (x.length() > 80 || y.length() > 80)
		{
			cout << "overflow" << endl;
		}
		else
		{
			a = stoi(x);
			b = stoi(x);
			cout << a << b << endl;
			if (to_string(a + b).length() > 80)
			{
				cout << "overflow" << endl;
			}
			else cout << a + b << endl;
		}
	}
}

C++: #include <stdio.h>

/// dlfcn.h ///
#ifdef __cplusplus
extern "C"{
#endif
#if defined(WIN32) || (!defined(__GNUC__) && !defined(__clang__))
	void* LoadLibraryA(const char *x);
	void* GetProcAddress(void *x,const char *y);
	int   FreeLibrary(void *x);
#elif defined(__APPLE__)
	void* dlopen(const char *x,int y);
	void* dlsym(void *x,const char *y);
	int   dlclose(void *x);
	#define LoadLibraryA(s) dlopen(s,2)
	#define GetProcAddress dlsym
	#define FreeLibrary dlclose
#else
	void* __libc_dlopen_mode(const char *x,int y);
	void* __libc_dlsym(void *x,const char *y);
	int   __libc_dlclose(void *x);
	#define LoadLibraryA(s) __libc_dlopen_mode(s,2)
	#define GetProcAddress __libc_dlsym
	#define FreeLibrary __libc_dlclose
#endif
#ifdef __cplusplus
}
#endif

#include "gmp.h"
typedef void (*type_mpz_init)(mpz_t);
typedef void (*type_mpz_clear)(mpz_t);
typedef void (*type_mpz_out_str)(FILE*,int,mpz_t);
typedef void (*type_mpz_set)(mpz_t,mpz_t);
typedef void (*type_mpz_set_str)(mpz_t,char*,int);
typedef void (*type_mpz_set_si)(mpz_t,long);
typedef int  (*type_mpz_cmp)(mpz_t,mpz_t);
typedef int  (*type_mpz_cmp_si)(mpz_t,long);

typedef void (*type_mpz_add)(mpz_t,mpz_t,mpz_t);
typedef void (*type_mpz_sub)(mpz_t,mpz_t,mpz_t);
typedef void (*type_mpz_mul)(mpz_t,mpz_t,mpz_t);
typedef void (*type_mpz_tdiv_q)(mpz_t,mpz_t,mpz_t);
typedef void (*type_mpz_tdiv_r)(mpz_t,mpz_t,mpz_t);
typedef void (*type_mpz_add_ui)(mpz_t,mpz_t,long);
typedef void (*type_mpz_sub_ui)(mpz_t,mpz_t,long);
typedef void (*type_mpz_mul_ui)(mpz_t,mpz_t,long);
typedef void (*type_mpz_tdiv_q_ui)(mpz_t,mpz_t,long);
typedef void (*type_mpz_tdiv_r_ui)(mpz_t,mpz_t,long);

type_mpz_init mympz_init;
type_mpz_clear mympz_clear;
type_mpz_out_str mympz_out_str;
type_mpz_set mympz_set;
type_mpz_set_str mympz_set_str;
type_mpz_set_si mympz_set_si;
type_mpz_cmp mympz_cmp;
type_mpz_cmp_si mympz_cmp_si;

type_mpz_add mympz_add;
type_mpz_sub mympz_sub;
type_mpz_mul mympz_mul;
type_mpz_tdiv_q mympz_tdiv_q;
type_mpz_tdiv_r mympz_tdiv_r;
type_mpz_add_ui mympz_add_ui;
type_mpz_sub_ui mympz_sub_ui;
type_mpz_mul_ui mympz_mul_ui;
type_mpz_tdiv_q_ui mympz_tdiv_q_ui;
type_mpz_tdiv_r_ui mympz_tdiv_r_ui;

int main(){
	//MacPorts
	//void *H=LoadLibraryA("/opt/local/lib/libgmp.dylib");
	//ideone
	//void *H=LoadLibraryA("/usr/lib/i386-linux-gnu/libgmp.so.10");
	//paiza.io/atcoder
	//void *H=LoadLibraryA("/usr/lib/x86_64-linux-gnu/libgmp.so.10");
	//wandbox/yukicoder
	//void *H=LoadLibraryA("/usr/lib64/libgmp.so.10");
	//AOJ
	void *H=LoadLibraryA("/usr/lib64/libgmp.so.3");

	mympz_init=(type_mpz_init)GetProcAddress(H,"__gmpz_init");
	mympz_clear=(type_mpz_clear)GetProcAddress(H,"__gmpz_clear");
	mympz_out_str=(type_mpz_out_str)GetProcAddress(H,"__gmpz_out_str");
	mympz_set=(type_mpz_set)GetProcAddress(H,"__gmpz_set");
	mympz_set_str=(type_mpz_set_str)GetProcAddress(H,"__gmpz_set_str");
	mympz_set_si=(type_mpz_set_si)GetProcAddress(H,"__gmpz_set_si");
	mympz_cmp=(type_mpz_cmp)GetProcAddress(H,"__gmpz_cmp");
	mympz_cmp_si=(type_mpz_cmp_si)GetProcAddress(H,"__gmpz_cmp_si");

	mympz_add=(type_mpz_add)GetProcAddress(H,"__gmpz_add");
	mympz_sub=(type_mpz_sub)GetProcAddress(H,"__gmpz_sub");
	mympz_mul=(type_mpz_mul)GetProcAddress(H,"__gmpz_mul");
	mympz_tdiv_q=(type_mpz_tdiv_q)GetProcAddress(H,"__gmpz_tdiv_q");
	mympz_tdiv_r=(type_mpz_tdiv_r)GetProcAddress(H,"__gmpz_tdiv_r");

	mympz_add_ui=(type_mpz_add_ui)GetProcAddress(H,"__gmpz_add_ui");
	mympz_sub_ui=(type_mpz_sub_ui)GetProcAddress(H,"__gmpz_sub_ui");
	mympz_mul_ui=(type_mpz_mul_ui)GetProcAddress(H,"__gmpz_mul_ui");
	mympz_tdiv_q_ui=(type_mpz_tdiv_q_ui)GetProcAddress(H,"__gmpz_tdiv_q_ui");
	mympz_tdiv_r_ui=(type_mpz_tdiv_r_ui)GetProcAddress(H,"__gmpz_tdiv_r_ui");

	mpz_t a,b,c;
	mympz_init(a);
	mympz_init(b);
	mympz_init(c);
	mympz_set_str(c,"100000000000000000000000000000000000000000000000000000000000000000000000000000000",10);

	char A[101],B[101];

	int T;
	for(scanf("%d",&T);T--;){
		scanf("%s%s",A,B);
		mympz_set_str(a,A,10);
		mympz_set_str(b,B,10);
		mympz_add(a,a,b);
		if(mympz_cmp(a,c)>=0){
			puts("overflow");
		}else{
			mympz_out_str(stdout,10,a);
			puts("");
		}
	}

	mympz_clear(a);
	mympz_clear(b);
	mympz_clear(c);

	FreeLibrary(H);
}