#!/usr/bin/python

import sys

f1_data = []
f2_data = []
res_data = []

with open(str(sys.argv[1])) as load_file1, open(str(sys.argv[2])) as load_file2, open(str(sys.argv[3]), 'w+') as res:


  for line in load_file1:
    f1_data.append(line.split())

  for line1 in load_file2:
    f2_data.append(line1.split())

  for item in range(len(f1_data)):

    temp_list = []

    for i in range(3):
      n1 = f1_data[item][i]
      n2 = f2_data[item][i]

      temp_list.append(float(n1) + float(n2))

    res_data.append(temp_list)

  for line in res_data:

    print(line)
      
    l__ = ""

    for i in range(3):
      l__ += str(line[i]) + " "

    res.write(l__ + "\n")
    
