'''
每一个n维点到中心点的距离都相等,根据这个性质联立方程组,最终合可以化为一个
n元一次方程组,用高斯消元求解即可
'''
n = int(input())
a = []
for i in range(n+1):
a.append(list(map(float, input().split())))
m = [[0]*(n+1) for _ in range(n)]
# 构建方程组的增广矩阵
for i in range(n):
S = 0
for j in range(n):
m[i][j] = 2 * (a[i][j] - a[i+1][j])
S += a[i][j]**2 - a[i+1][j]**2
m[i][n] = S
#print(m)
EPSLON = 1e-7
def is_zero(val):
return abs(val) <= EPSLON
# 高斯消元
for col in range(0, n):
max_val, max_row = abs(m[col][col]), col
for row in range(col+1, n):
if abs(m[row][col]) > abs(max_val):
max_val, max_row = abs(m[row][col]), row
if is_zero(max_val):
continue
m[col], m[max_row] = m[max_row], m[col]
for row in range(col+1, n):
k = m[row][col] / m[col][col]
for j in range(col, n+1):
m[row][j] -= m[col][j] * k
flag = 0
ans = [0.0] * n
for i in range(n-1, -1, -1):
val, k = m[i][n], m[i][i]
s = 0.0
for j in range(n-1, i, -1):
s += m[i][j] * ans[j]
val -= s
ans[i] = val / k
for val in ans:
print('{:.3f}'.format(val), end=' ')
print()