let to_list str =
  let n = String.length str in
  let rec doit i acc =
    if i = n then acc
    else doit (i + 1) (str.[i] :: acc)
  in
  doit 0 []

let to_int c = int_of_char c - int_of_char '0'

let plus l1 l2 =
  let rec doit l1 l2 i carry acc =
    if l1 = [] && l2 = [] then (i, if carry = 1 then (1 :: acc) else acc)
    else if l1 = [] then
      let x = to_int (List.hd l2) + carry in
      if x <= 9 then doit [] (List.tl l2) (i + 1) 0 (x :: acc)
      else doit [] (List.tl l2) (i + 1) 1 (x mod 10 :: acc)
    else if l2 = [] then
      let x = to_int (List.hd l1) + carry in
      if x <= 9 then doit (List.tl l1) [] (i + 1) 0 (x :: acc)
      else doit (List.tl l1) [] (i + 1) 1 (x mod 10 :: acc)
    else
      let x = to_int (List.hd l1) + to_int (List.hd l2) + carry in
      if x <= 9 then doit (List.tl l1) (List.tl l2) (i + 1) 0 (x :: acc)
      else doit (List.tl l1) (List.tl l2) (i + 1) 1 (x mod 10 :: acc)
  in
  doit (to_list l1) (to_list l2) 0 0 []

let () =
  let n = read_int () in
  let rec doit i =
    if i < n then begin
      let l1 = read_line () in
      let l2 = read_line () in
      if String.length l1 < 9 && String.length l2 < 9 then Printf.printf "%d\n" (int_of_string l1 + int_of_string l2)
      else begin
        let z, ans = plus l1 l2 in
        if z >= 80 then print_endline "overflow"
        else (List.iter (fun e -> print_int e) ans; print_newline ())
      end;
      doit (i + 1)
    end
  in
  doit 0