import Control.Applicative
import Control.Monad
import Data.List

dst :: (Int, Int) -> (Int, Int) -> Int
dst (x1, y1) (x2, y2) = abs (x2 - x1) + abs (y2 - y1)

f1 :: (Int, Int, Int) -> [(Int, Int, Int)]
f1 (x, y, h) =
    [(cx, cy, h + dst (x, y) (cx, cy)) | cx <- [0 .. 100] , cy <- [0 .. 100]]

f2 :: [(Int, Int, Int)] -> (Int, Int, Int) -> Bool
f2 xyhs cxyh = and $ fmap (f3 cxyh) xyhs
  where
    f3 (cx, cy, ch) (x, y, h)
        = (max (ch - dst (cx, cy) (x, y)) 0) == h

main :: IO ()
main = do
    n <- readLn
    xyhs <- replicateM n $ do
        [x, y, h] <- fmap read . words <$> getLine :: IO [Int]
        return (x, y, h)
    let xyh = head $ filter (\(_, _, h) -> h > 0) xyhs
    let cxyhs = f1 xyh
    let (ax, ay, ah) = head $ filter (f2 xyhs) cxyhs
    putStrLn $ unwords $ fmap show [ax, ay, ah]