import Control.Monad
import Data.List
import qualified Data.Set as S

main = do
    [x, y, z, k] <- map read <$> words <$> getLine
    a   <- sort <$> map read <$> words <$> getLine
    b   <- sort <$> map read <$> words <$> getLine
    c   <- sort <$> map read <$> words <$> getLine
    forM_ (solve k a b c) $ \ret -> putStrLn (show ret)

solve :: Int -> [Integer] -> [Integer] -> [Integer] -> [Integer]
solve k a b c = doit q m k
  where
    (q, m) = qpush S.empty S.empty (length a - 1) (length b - 1) (length c - 1)
    qpush q m ai bi ci | ai < 0 || bi < 0 || ci < 0 = (q, m)
                       | S.member (ai, bi, ci) m    = (q, m)
                       | otherwise                  = (newq, newm)
      where
        newq = S.insert (a !! ai + b !! bi + c !! ci, ai, bi, ci) q
        newm = S.insert (ai, bi, ci) m
    doit q m 0 = []
    doit q m k = s : doit q3 m3 (k - 1)
      where
        ((s, ai, bi, ci), q0) = S.deleteFindMax q
        (q1, m1) = qpush q0 m  (ai - 1) bi ci
        (q2, m2) = qpush q1 m1 ai (bi - 1) ci
        (q3, m3) = qpush q2 m2 ai bi (ci - 1)