Problem:
National Budget A country has a budget of more than 81 trillion yen. We want to process such data, but conventional integer type which uses signed 32 bit can represent up to 2,147,483,647. Your task is to write a program which reads two integers (more than or equal to zero), and prints a sum of these integers. If given integers or the sum have more than 80 digits, print "overflow". Input Input consists of several datasets. In the first line, the number of datasets N (1 ≤ N ≤ 50) is given. Each dataset consists of 2 lines: The first integer
The second integer The integer has at most 100 digits. Output For each dataset, print the sum of given integers in a line. Sample Input 6
1000
800
9999999999999999999999999999999999999999
1
99999999999999999999999999999999999999999999999999999999999999999999999999999999
1
99999999999999999999999999999999999999999999999999999999999999999999999999999999
0
100000000000000000000000000000000000000000000000000000000000000000000000000000000
1
100000000000000000000000000000000000000000000000000000000000000000000000000000000
100000000000000000000000000000000000000000000000000000000000000000000000000000000 Output for the Sample Input 1800
10000000000000000000000000000000000000000
overflow
99999999999999999999999999999999999999999999999999999999999999999999999999999999
overflow
overflow

Solution (Python):
import math
count=int(input())
for i in range(count):
    x=int(input())
    y=int(input())
    ans=x+y
    dif=100000000000000000000000000000000000000000000000000000000000000000000000000000000
    if ans>=dif:
        print("overflow")
    else:
        print(ans)

Solution (Python):

if __name__ == '__main__':
    n = (int)(input())
    for _ in range(n):
        sNumber = (int)(input())
        tNumber = (int)(input())
        uNumber = sNumber+tNumber
        print("overflow" if uNumber >= 10**80 else uNumber)

Solution (Python):
n = int(input())
for _ in range(n):
    a = input()
    b = input()
    c = int(a) + int(b)
    if len(str(c)) > 80:
        print("overflow")
    else:
        print(c)

Solution (Python):


n = input()
for i in range(1, n + 1):
    a = long(raw_input())
    b = long(raw_input())
    c = a + b
    d = c
    digit = 0
    while c > 0:
        c = c / 10
        digit += 1

    if digit > 80:
        print 'overflow'
    else:
        print d

Solution (Python):
def main():
    n = int(input())
    Upper = 10**80
    for i in range(n):                       
            a = int(input())
            b = int(input())
            if a+b >= Upper:
                print("overflow")
            else:
                print(a+b)
if __name__ =='__main__':
    main()

Solution (Python):
n = int(input())
for i in range(0, n) :
  a = int(input())
  b = int(input())
  sum = a + b
  if len(str(sum)) > 80 :
    print("overflow")
  else :
    print(sum)

Solution (Python):
for i in range(int(input())):
  ans = int(input()) + int(input())
  print(ans if len(str(ans)) <= 80 else "overflow")

Solution (Python):
n = int(input())
for i in range(n):
	a = int(input())
	b = int(input())
	
	if (a+b) < (10**80):
		print(a+b)
	else:
		print("overflow")

Solution (Python):
n = int(input())
for i in range(n):
    x = int(input())
    y = int(input())
    if len(str(x + y)) > 80:
        print("overflow")
    else:
        print(x + y)

Solution (Python):
import math

def calc_digit(data1, data2):
    if(data1 == 0):
        data_size2 = int(len(str(data2)))
        data_size1 = 1
    elif(data2 == 0):
        data_size1 = int(len(str(data2)))
        data_size2 = 1
    else:
        data_size1 = int(len(str(data1)))
        data_size2 = int(len(str(data2)))
    return(data_size1, data_size2)

def two_number_sum(data1, data2):
    result = data1 + data2
    if int(len(str(result))) > 80:
        print("overflow")
    else:
        print(result)

def main():
    a = []
    N = int(input())
    for i in range(N*2):
        a.append(input())
    for i in range(0, N*2):
        if i % 2 == 0:
            continue
        else:
            data1 = int(a[i-1])
            data2 = int(a[i])
            if(data1 == None):
                data1 = 0
            elif(data2 == None):
                data2 = 0
            x, y = calc_digit(data1, data2)
            if(x > 80 or y > 80):
                print("overflow")
                continue
            two_number_sum(data1, data2)

if __name__ == '__main__':
    main()

Solution (Python):
n = int(raw_input())
for i in range(0,n):
    
    a = int(raw_input())
    b = int(raw_input())
    sum = a+b
    if len(str(sum)) <= 80:
        print sum
    else:
        print "overflow"

Solution (Python):


n = int(raw_input())

for i in range(n):
	n1 = int(raw_input())
	n2 = int(raw_input())
	sum = n1 + n2
	strsum = str(sum)
	if len(strsum) > 80:
		print("overflow")
	else:
		print(strsum)

Solution (Python):
N = int(input())
for _ in range(N):
    a = int(input())
    b = int(input())
    c = a + b
    length = len(str(c))
    print([c, "overflow"][length > 80])

Solution (Python):
N = int(input())
for i in range(N):
    a = int(input())
    b = int(input())
    ans = a + b
    if len(str(ans)) > 80:
        print("overflow")
    else:
        print(ans)

Solution (Python):
for _ in[0]*int(input()):
 s=int(input())+int(input())
 print([s,'overflow'][s>=10**80])

Solution (Python):
for _ in[0]*int(input()):
 s=eval(input()+'+'+input())
 print([s,'overflow'][s>=10**80])

Solution (Python):
n = int(input())
for i in range(n):
	x = int(input())
	y = int(input())
	ans = x + y
	if(ans < 10**80):
		print(ans)
	else:
		print("overflow")

Solution (Python):

n=int(input())
for _ in range(n):
    a=input()
    b=input()
    s=int(a)+int(b)
    if len(a)>80 or len(b)>80 or len(str(s))>80:
        print("overflow")
        continue
    else:
        print(s)

Solution (Python):
n = int(input())
for i in range(n):
  a = int(input())
  b = int(input())
  c = a + b
  if len(str(c)) > 80:
    print("overflow")
  else:
    print(c)

Solution (Python):
for _ in range(int(input())):
    a = int(input()) + int(input())
    print(a if len(str(a)) < 81 else "overflow")

Solution (Python):
o=map(str,[sum([int(input()) for j in range(2)]) for i in range(int(input()))])
[print(i) if len(i)<=80 else print("overflow") for i in o]

Solution (Python):
[print(i) if len(i)<=80 else print("overflow") for i in map(str,[sum([int(input()) for j in range(2)]) for i in range(int(input()))])]

Solution (Python):



n = int(input())
for i in range(n):
    a = str(input())
    b = str(input())
    if len(a) > 80 or len(b) > 80:
        print('overflow')
    else:
        s = str(int(a)+int(b))
        if len(s) <= 80:
            print(s)
        else:
            print('overflow')

Solution (Python):



n = int(input())
for i in range(n):
    s = int(input()) + int(input())
    if len(str(s)) <= 80:
        print(s)
    else:
        print('overflow')

Solution (Python):
n = int(input())
for _ in range(n):
    a = int(input())+int(input())
    if a >= 10**80:
        print("overflow")
    else:
        print(a)

Solution (Python):
n = int(raw_input())
for i in range(0, n):
    x = int(raw_input())
    y = int(raw_input())
    sum = str(x+y)
    if len(sum) > 80:
        print 'overflow'
    else:
        print sum

Solution (Python):
count =int(input())
for a in range(count):
  x,y=int(input()),int(input())
  ans = str(x+y)
  if len(ans) >80:print "overflow"
  else:
    print ans

Solution (Python):
count =int(input())
for a in range(count):
  x,y=int(input()),int(input())
  ans = str(x+y)
  if len(ans) >80:print "overflow"
  else:
    print ans

Solution (Python):
line_num = int(raw_input())
for n in range(line_num):
	a = raw_input()
	b = raw_input()
	if len(a) > 80 or len(b) > 80:
		print 'overflow'
	else:
		filled_a, filled_b = a.zfill(80), b.zfill(80)
		rlist_a = map(int,list(filled_a)[::-1])
		rlist_b = map(int,list(filled_b)[::-1])
		rlist_sum = []
		for n in range(80):
			rlist_sum.append(rlist_a[n]+rlist_b[n])
		for n in range(79):
			if rlist_sum[n] > 9:
				rlist_sum[n] -= 10
				rlist_sum[n+1] += 1
		if rlist_sum[79] > 9:
			print 'overflow'
		else:
			list_sum = []
			f = 0
			for n in rlist_sum[::-1]:
				if f > 0:
					list_sum.append(n)
				else:
					if n > 0:
						f = 1
						list_sum.append(n)
			ans = ''.join(map(str,list_sum))
			if len(ans) < 1:
				print '0'
			else:
				print ans

Solution (Python):
n=input()
for i in xrange(n):
    a=input()
    b=input()
    sum=str(a+b)
    if len(sum)>80:
        print "overflow"
    else :
        print sum

Solution (Python):
ds = int(raw_input())
for i in xrange(ds):
    x=int(raw_input())
    y=int(raw_input())
    sum = str(x+y)
    if len(sum) > 80:
        print "overflow"
    else:
        print sum

Solution (Python):
n=input()
for i in range(n):
    a=input()
    b=input()
    if len(str(a+b))>80:
        print "overflow"
    else:
        print a+b

Solution (Python):
def datasets():
    import sys
    for i in range(int(sys.stdin.readline().strip())):
        s1 = sys.stdin.readline().strip()
        s2 = sys.stdin.readline().strip()
        yield s1, s2

for s1, s2 in datasets():
    r = int(s1)+int(s2)
    if len(s1)>80 or len(s2)>80 or len(str(r))>80:
        print "overflow"
        continue
    print r

Solution (Python):
n = long(raw_input())
for i in range(n):
    a = long(raw_input())
    b = long(raw_input())
    c = a + b
    if(len(str(c)) > 80):
        print 'overflow'
    else:
        print c

Solution (Python):
for i in range(input()):
	x=input();y=input();
	if len(str(x+y))>80:
		print "overflow"
	else:
		print x+y

Solution (Python):
for i in range(input()):
 x=input();y=input();
 if len(str(x+y))>80:
  print "overflow"
 else:
  print x+y

Solution (Python):
for i in range(input()):
    x=input();y=input();
    if len(str(x+y))>80:
        print "overflow"
    else:
        print x+y

Solution (Python):
n = int(raw_input())
for i in range(n):
	a = int(raw_input())
	b = int(raw_input())
	sum = str(a + b)
	if len(sum) > 80:
		print("overflow")
	else:
		print(sum)

Solution (Python):
n = int(raw_input())
for i in range(0, n):
    x = int(raw_input())
    y = int(raw_input())
    sum = str(x+y)
    if len(sum) > 80:
        print 'overflow'
    else:
        print sum

Solution (Python):
for i in range(int(raw_input())):
    x = int(raw_input())
    y = int(raw_input())
    s = str(x+y)
    if len(s) > 80:
        print "overflow"
    else :
        print s

Solution (Python):
from __future__ import (absolute_import, division, print_function,
                        unicode_literals)
from sys import stdin

n = int(stdin.readline())
while n:
    result = long(stdin.readline()) + long(stdin.readline())
    if len(str(result)) >= 81:
        print('overflow')
    else:
        print(result)
    n -= 1

Solution (Python):
'''
Created on Mar 21, 2013

@author: wukc
'''

from sys import stdin

n=int(stdin.readline())
for i in range(n):
    a,b=[stdin.readline().strip().lstrip("0") for k in range(2)]
    if len(a)>80 or len(b)>80:
        print("overflow")
        continue
    a,b=a.rjust(len(b),'0'),b.rjust(len(a),'0')
    ans=[]
    c=0
    for x,y in zip(a[::-1],b[::-1]):
        t=int(x)+int(y)+c
        c=t//10
        ans+=[t%10]
    ans+=[c]
    ans="".join(map(str,ans[::-1])).lstrip("0")
    if len(ans)>80:
        print("overflow")
        continue
    print(ans.rjust(1,'0'))

Solution (Python):
for val in xrange(0,input()):
	a = input()
	b = input()
	c = a+b
	if len(str(a)) <= 80 and len(str(b)) <= 80 and len(str(c)) <= 80: print c
	else: print 'overflow'

Solution (Python):
n=int(raw_input())
for i in range(0,n):
  a=int(raw_input())
  b=int(raw_input())
  c=str(a+b)
  if len(c)<=80:
    print c
  else:
    print "overflow"

Solution (Python):
n=input()
for i in range(n):
    x=input()
    y=input()
    if 80<len(str(x)) or 80<len(str(y)): print 'overflow'
    else:
        ans=x+y
        if 80<len(str(ans)): print 'overflow'
        else: print x+y

Solution (Python):
n = int(raw_input())

for i in range(0,n):
    a = int(raw_input())
    b = int(raw_input())
    ans = str(a+b)

    if len(ans) > 80:
        print 'overflow'
    else:
        print ans

Solution (Python):
def isoverflow(s):
    if len(s)>80: return True
    else: return False

n = input()

for i in range(n):
    a = input()
    b = input()

    if isoverflow(str(a)) or isoverflow(str(b)): print "overflow"
    else:
         tmp = a+b
         if isoverflow(str(tmp)): print "overflow"
         else: print tmp

Solution (Python):
n = int(raw_input())
for _ in range(n):
    r = int(raw_input()) + int(raw_input())
    if len(str(r)) > 80:
        print 'overflow'
    else:
        print r

Solution (Python):


num_inputs = int(raw_input())

limit = 100000000000000000000000000000000000000000000000000000000000000000000000000000000

count = 0
while count < num_inputs:
	num1 = int(raw_input())
	num2 = int(raw_input())

	if num1 >= limit or num2 >= limit:
		print('overflow')
	else:
		num = num1 + num2
		if num >= limit:
			print('overflow')
		else:
			print(num)

	count += 1

Solution (Python):
for x in range(input()):
    a = input() + input()
    print a if len(str(a)) < 81 else "overflow"

Solution (Python):
n = int(raw_input())
for i in range(n):
    a = long(raw_input())
    b = long(raw_input())
    s = a + b
    if s >= pow(10, 80):
        print "overflow"
    else:
        print s

Solution (Python):

import math
n = input()
for i in range(n):
  a = input() + input()
  if(len(str(a)) > 80):
    print "overflow"
  else:
    print a

Solution (Python):
for i in range(int(raw_input())):
    x = int(raw_input())
    y = int(raw_input())
    s = str(x+y)
    if len(s) > 80:
        print "overflow"
    else :
        print s

Solution (Python):
n = int(raw_input())

for i in range(n):
    a = long(raw_input())
    b = long(raw_input())
    c = a+b
    if len(str(c)) > 80:
        print "overflow"
    else:
        print c

Solution (Python):
import sys

n = input()
for i in range(n):
    a = list(reversed(map(int, raw_input())))
    b = list(reversed(map(int, raw_input())))
    if len(a) < len(b):
        a, b = b, a
    for j in range(len(a)):
        if j < len(b):
            a[j] += b[j]
        if a[j] >= 10:
            a[j] -= 10
            if j != len(a) - 1:
                a[j + 1] += 1
            else:
                a.insert(len(a), 1)
    if len(a) > 80:
        print "overflow"
    else:
        for x in reversed(a):
            sys.stdout.write("%d" %x)
        print

Solution (Python):
s="overflow"
n=input()
for i in range(n):
  a=raw_input()
  b=raw_input()
  if len(a)>80 or len(b)>80: print s
  else:
    tmp=int(a)+int(b)
    if len(str(tmp))>80: print s
    else: print tmp

Solution (Python):
m=10**80
n=input()
for i in range(n):
  s="overflow"
  a=input()
  b=input()
  if a<m and b<m:
    tmp=a+b
    if tmp<m: s=tmp
  print s

Solution (Python):
n=input()
for i in range(n):
  a=input()
  b=input()
  c=a+b
  if len(str(c))>80: print "overflow"
  else: print c

Solution (Python):
n = int(raw_input())
for i in range(n):
    a = int(raw_input())
    b = int(raw_input())
    if a+b >= 10**80: print 'overflow'
    else: print a+b

Solution (Python):
for i in range(int(raw_input())):
    a = str(int(raw_input()) + int(raw_input()))
    print 'overflow' if len(a) > 80 else a

Solution (Python):
n = int(input())
for i in range(n):
  sum = int(input()) + int(input())
  if len(str(sum)) >= 81:
    print 'overflow'
  else:
    print sum

Solution (Python):
n = int(input())
for i in range(n):
  sum = long(input()) + long(input())
  if len(str(sum)) >= 81:
    print 'overflow'
  else:
    print sum

Solution (Python):
n = input()
for i in range(n):
    m = input() + input()
    if len(str(m)) >= 81:
        print 'overflow'
    else:
        print m

Solution (Python):
n = input()
for _ in xrange(n):
    a, b = input(), input()
    ret = a + b
    overflow = 10 ** 80
    if a + b >= overflow:
        print 'overflow'
    else:
        print ret

Solution (Python):
LIMIT = 10 ** 80
n = int(input())
for i in range(n):
    a = int(input())
    b = int(input())
    c = a + b
    if a >= LIMIT or b >= LIMIT or c >= LIMIT:
        print('overflow')
    else:
        print(c)

Solution (Python):
import re

def readline():
    return raw_input()

def split8by10(str):
    str = str.rjust(80,'0')
    ss = []
    for s in range(0,len(str),8):
        ss.append(int(str[s:s+8]))
    return ss

def add8by10(a,b):
    c = [0 for i in range(0,10)]
    p = 10**8
    for i in reversed(range(0,10)):
        c[i] += a[i] + b[i]
        if c[i] >= p:
            if i > 0:
                c[i-1] += c[i] // p
            else:
                return None
        c[i] = c[i] % p
    return c

n = int(readline())
for i in range(0,n):
    a = readline()
    b = readline()
    if len(a) > 80 or len(b) > 80:
        print "overflow"
        continue
    a = split8by10(a)
    b = split8by10(b)
    c = add8by10(a,b)
    if c is None:
        print "overflow"
    else:
        print re.sub('^0{,79}',"","".join(map(lambda x:str(x).rjust(8,'0'),c)))

Solution (Python):
n=input()
for i in range(0,n):
 a=input()
 b=input()
 s=str(a+b)
 if(len(s)<=80): print a+b
 else: print "overflow"

Solution (Python):
def digits(n):
    if n < 10: return 1
    c = 0
    while n > 0:
        c += 1
        n = n // 10

    return c

n = int(input())
for i in range(n):
    u = int(input())
    v = int(input())
    s = u + v
    if (digits(u) > 80 or digits(v) > 80 or digits(s) > 80):
        print("overflow")
    else:
        print(s)

Solution (Python):

import math

n=int(input())

for i in range(n):
    a=int(input())
    b=int(input())
    st=str(a+b)
    if len(st)>80:
        print("overflow")
    else:
        print(st)

Solution (Python):
n = int(input())
for i in range(n) :
    a = input()
    b = input()
    if len(a) > 80 or len(b) > 80 :
        print("overflow")
    else :
        ans = str(int(a)+int(b))
        if len(ans) > 80 :
            print("overflow")
        else :
            print(int(a) + int(b))

Solution (Python):
n = int(input())
for i in range(n):
    num1 = int(input())
    num2 = int(input())
    num3 = num1 + num2
    k = len(str(num3))
    if k > 80:
        print("overflow")
    else:
        print(num3)

Solution (Python):

j = int(input())
for _ in range(j):
    a = int(input())
    b = int(input())
    
    
    num = a + b
    
    
    num1 = [c for c in str(num)]
    if len(num1) > 80:num = "overflow"
    else:pass
    print(num)

Solution (Python):
N = int(input())
for i in range(N):
    a = int(input())
    b = int(input())
    c = a+b
    if len(str(c)) > 80:
        print("overflow")
    else:
        print(c)

Solution (Python):
n = int(input())
for i in range(n):
    a = int(input())
    b = int(input())
    s = a + b
    if len(str(s)) > 80 :
        print("overflow")
    else:
        print(s)

Solution (Python):
[print((lambda x:x if x<10**80 else "overflow")(int(input())+int(input()))) for i in range(int(input()))]

Solution (Python):
for i in range(int(input())):
    a = int(input())
    b = int(input())

    result = a + b
    if len(str(result)) > 80:
        print('overflow')
    else:
        print(result)

Solution (Python):
if __name__ == '__main__':
    N = int(input())
    for _ in range(N):
        a = input()
        b = input()
        c = str(int(a) + int(b))
        if len(a) > 80 or len(b) > 80 or len(c) > 80:
            print("overflow")
        else:
            print(c)

Solution (Python):
while 1:
    try:
        n = int(input())
    except:break

    n1 = 0
    n2 = 0
    for i in range(n):
        n1 = int(input())
        n2 = int(input())
        isOver = False
        ans = n1 + n2
        if len(str(ans)) >= 81 | len(str(n1)) | len(str(n1)) :
            isOver = True
        if isOver:
            print("overflow")
        else:
            print(ans)

Solution (Python):
N = int(input())

list = []
for n in range(0, N):
    tmp = []
    for _ in range(0, 2):
        tmp.append(int(input()))
    list.append(tmp)

for a, b in list:
    c = a + b
    if c >= 10 ** 80:
        print('overflow')
    else:
        print(str(c))

Solution (Python):
import heapq
from collections import deque
from enum import Enum
import sys
import math
from _heapq import heappush, heappop
import copy

BIG_NUM = 2000000000
HUGE_NUM = 99999999999999999
MOD = 1000000007
EPS = 0.000000001
sys.setrecursionlimit(100000)


num_query = int(input())

for _ in range(num_query):
    A = list(map(int,input()))
    B = list(map(int,input()))

    if len(A) > 80 or len(B) > 80:
        print("overflow")
        continue

    if len(B) > len(A): 
        A,B = B,A
    A.reverse()
    B.reverse()

    ANS = deque()
    add = 0

    for digit in range(len(A)):
        if digit >= len(B):
            tmp = add+A[digit]
            add = tmp//10
            ANS.append(tmp%10)
        else:
            tmp = add+B[digit]+A[digit]
            add = tmp//10
            ANS.append(tmp%10)

    if len(A) == 80 and add == 1:
        print("overflow")
    else:
        if add == 1:
            ANS.append(1)

        while len(ANS) > 0:
            print("%d"%(ANS.pop()),end="")
        print()

Solution (Python):
n = int(input())
for _ in range(n):
    a = int(input())
    b = int(input())
    c = a + b
    if max(len(str(a)), len(str(b)), len(str(c))) > 80:
        print("overflow")
    else:
        print(c)

Solution (Python):
n = int(input())
for i in range(n):
    a = int(input())
    b = int(input())
    if len(str(a + b)) > 80:
        print('overflow')
    else:
        print(a+b)

Solution (Python):
n = int(input())
for i in range(n):
    a = int(input())
    b = int(input())
    if (a + b) // (10 ** 80) > 0:
        print('overflow')
    else:
        print(a + b)

Solution (Python):
m = 100000000000000000000000000000000000000000000000000000000000000000000000000000000
n = int(input())
for i in range(n):
    a = int(input())
    b = int(input())
    sum = a + b
    if sum > m or sum == m:
        print("overflow")
    else:
        print(sum)

Solution (Python):
n = int(input())
for i in range(n):
    s = int(input()) + int(input())
    if len(str(s)) <= 80:
        print(s)
    else:
        print('overflow')

Solution (Python):
n = int(input())
for i in range(n):
    s = int(input()) + int(input())
    if len(str(s)) <= 80:
        print(s)
    else:
        print('overflow')

Solution (Python):
n =int(input())
for i in range(n):
  a =int(input())
  b=int(input())

  if (a+b)<(10 **80):
    print(a+b)
  else:
    print("overflow")

Solution (Python):
n=int(input())
for i in range(n):
    a=input()
    b=input()
    s=int(a)+int(b)
    if len(str(s))>80:
        print("overflow")
    else:
        print(s)

Solution (Python):
N=int(input())
for i in range(N):
    a=int(input())
    b=int(input())
    retval=a+b
    if len(str(retval))>80:
        print("overflow")
    else:
        print(retval)

Solution (Python):
n=int(input())
for i in range(n):
    a,b=[int(input()) for _ in range(2)]
    print("overflow" if len(str(a+b))>80 else a+b)

Solution (Python):
if __name__ == '__main__':

	n = int(input())

	for i in range(n):
		a = int(input())
		b = int(input())

		if len(str(a+b)) > 80:
			print("overflow")
		else:
			print(a+b)

Solution (Python):
n = int(input())
for i in range(n):
  a = input()
  b = input()
  if len(a) > 80 or len(b) > 80:
    print("overflow")
  else:
    aa = int(a)
    bb = int(b)
    c = str(aa + bb)
    if len(c) > 80:
      print("overflow")
    else:
      print(c)

Solution (Python):
n = int(input())
for i in range(n):
  a = int(input())
  b = int(input())
  if len(str(a+b)) > 80:
    print("overflow")
  else:
    print(a+b)

Solution (Python):
while True:
    try:
        N=int(input())
        for i in range(N):
            a=input()
            b=input()
            if len(a)>80 or len(b)>80:
                print("overflow")
            else:
                a=int(a)
                b=int(b)
                s=a+b
                if len(str(s))>80:
                    print("overflow")
                else:
                    print(s)
    except:break

Solution (Python):
num_datasets = int(input())

for i in range(num_datasets):
    n = input().strip()
    m = input().strip()
    first_num_str = ""
    second_num_str = ""
    if len(n) > len(m):
        first_num_str = n
        second_num_str = m
    else:
        first_num_str = m
        second_num_str = n
    total = ""
    carry = 0
    first_int = 0
    second_int = 0
    first_last_index = len(first_num_str)-1
    second_last_index = len(second_num_str)-1
    for i in range(len(first_num_str)):
        first_int = int(first_num_str[first_last_index-i])
        if i < len(second_num_str):
            second_int = int(second_num_str[second_last_index-i])
        else:
            second_int = 0
        added = (first_int + second_int + carry) % 10
        carry = (first_int + second_int + carry) // 10
        total = str(added) + total
    if carry > 0:
        total = str(carry) + total
    if len(total) > 80:
        print("overflow")
    else:
        print(total)

Solution (Python):
import math
n=int(input())
s=[int(input()) for _ in range(n*2)]
for i in range(n):
  a=s[i*2]+s[i*2+1]
  st=str(a)
  if len(st)>80:
    print("overflow")
  else:
    print(a)

Solution (Python):
n = int(input())
for i in range(n):
    a = int(input())
    b = int(input())
    c = a+b
    if c >= (10**80):
        print("overflow")
    else:
        print(c)

Solution (Python):

n = int(input())
for _ in range(n):
    m1, m2 = int(input()), int(input())
    print(m1 + m2 if len(str(m1 + m2)) <= 80 else 'overflow')

Solution (Python):
n = int(input())
for _ in range(n):
    a = int(input())
    b = int(input())
    s = a + b
    if len(str(s)) > 80:
        print("overflow")
    else:
        print(s)

Solution (Python):
N = int(input())
num = [sum([int(input()) for _ in range(2)]) for _ in range(N)]

for n in num:
    if n < 10**80:
        print(n)
    else:
        print('overflow')

Solution (Python):

def align_digits(a, b):
    la, lb = len(a), len(b)
    if la < lb:
        a = a.zfill(lb)
    elif lb < la:
        b = b.zfill(la)
    return a, b


def add(a, b):
    a, b = align_digits(a, b)
    zipped = list(zip(a[::-1], b[::-1]))
    carry = 0
    result = []
    for i, z in enumerate(zipped):
        a, b = z
        s = int(a) + int(b) + carry
        carry = int(s / 10)
        if i == len(zipped) - 1:
            result.append(str(s))
        else:
            result.append(str(s % 10))
    ans = ''.join(result[::-1])
    if len(ans) > 80:
        return 'overflow'
    return ans


if __name__ == '__main__':
    n_input = int(input())
    inputs = []
    for i in range(n_input):
        inputs.append((input(), input()))
    for a, b in inputs:
        print(add(a, b))

Solution (Python):
n = int(input())
for _ in range(n):
    s1 = int(input())
    s2 = int(input())
    s3 = s1+s2
    if len(str(s3)) > 80:
        print("overflow")
    else:
        print(s3)

Solution (Python):
def run():
    N = int(input())
    for _ in range(N):
        x = int(input())
        y = int(input())
        if 80 < len(str(x)) or 80 < len(str(y)) or 80 < len(str(x+y)):
            print('overflow')
        else:
            print(x+y)

if __name__ == '__main__':
    run()

Solution (Python):
n = int(input())

for i in range(n):
  a = int(input())
  b = int(input())
  s = a+b

  if len(str(s)) > 80:
    print("overflow")
  else:
    print(s)

Solution (Python):
for i in range(int(input())):
    s=int(input())+int(input())
    if s>=int("1"+"0"*80):
        print("overflow")
    else:
        print(s)

Solution (Python):
n = int(input())
for i in range(n):
    a = int(input())
    b = int(input())
    if (a+b) < (10**80):
        print(a+b)
    else:
        print("overflow")

Solution (Python):


import math

BIG_NUM = 100000000000000000000000000000000000000000000000000000000000000000000000000000000


def main():
    n = int(input())
    for _ in range(n):
        a = int(input())
        b = int(input())
        if a >= BIG_NUM  or b >= BIG_NUM or a + b >= BIG_NUM:
            print("overflow")
        else:
            print(a+b)

if __name__ == "__main__":
    main()

Solution (Python):

md = 80
for _ in range(int(input())):
    a,b = int(input()),int(input())
    ab = a + b
    if a >= pow(10,md) or b >= pow(10,md) or ab >= pow(10,md):
        print('overflow')
    else:
        print(a+b)