N = int(eval(input()))



xyh = [tuple(map(int, input().split())) for _ in range(N)]



for cx in range(0, 101):

    for cy in range(0, 101):

        flag = True



        for i, (x,y,h) in enumerate(xyh):

            if h != 0:

                H = h + abs(x - cx) + abs(y - cy)



        for i, (x,y,h) in enumerate(xyh):

            if h == max(H - abs(x - cx) - abs(y - cy), 0):

                continue

            else:

                flag = False

                break

        if flag:

            print((cx, cy, H))

            exit()







N = int(eval(input()))

HXY = []

for i in range(N):

    x,y,h = list(map(int, input().split()))

    HXY.append((h,x,y))







HXY.sort(reverse=True)



for cx in range(101):

    for cy in range(101):

        H = HXY[0][0] + abs(HXY[0][1] - cx) + abs(HXY[0][2] - cy)

        is_valid = True

        for h,x,y in HXY:

            if h == max(H - abs(x - cx) - abs(y - cy), 0):

                continue

            else:

                is_valid = False

                break

        if is_valid:

            print((cx, cy, H))

            exit()

             
N = int(eval(input()))
xyh = [tuple(map(int, input().split())) for _ in range(N)]
for cx in range(0, 101):
    for cy in range(0, 101):
        flag = True
        for i, (x, y, h) in enumerate(xyh):
            if h != 0:
                H = h + abs(x - cx) + abs(y - cy)
        for i, (x, y, h) in enumerate(xyh):
            if h == max(H - abs(x - cx) - abs(y - cy), 0):
                continue
            else:
                flag = False
                break
        if flag:
            print((cx, cy, H))
            exit()

N = int(eval(input()))
HXY = []
for i in range(N):
    x, y, h = list(map(int, input().split()))
    HXY.append((h, x, y))
HXY.sort(reverse=True)
for cx in range(101):
    for cy in range(101):
        H = HXY[0][0] + abs(HXY[0][1] - cx) + abs(HXY[0][2] - cy)
        is_valid = True
        for h, x, y in HXY:
            if h == max(H - abs(x - cx) - abs(y - cy), 0):
                continue
            else:
                is_valid = False
                break
        if is_valid:
            print((cx, cy, H))
            exit()

-xyh = [tuple(map(int, input().split())) for _ in range(N)] -for cx in range(0, 101): -    for cy in range(0, 101): -        flag = True -        for i, (x, y, h) in enumerate(xyh): -            if h != 0: -                H = h + abs(x - cx) + abs(y - cy) -        for i, (x, y, h) in enumerate(xyh): +HXY = [] +for i in range(N): +    x, y, h = list(map(int, input().split())) +    HXY.append((h, x, y)) +HXY.sort(reverse=True) +for cx in range(101): +    for cy in range(101): +        H = HXY[0][0] + abs(HXY[0][1] - cx) + abs(HXY[0][2] - cy) +        is_valid = True +        for h, x, y in HXY: -                flag = False +                is_valid = False -        if flag: +        if is_valid: