meta = STDIN.gets().split(" ")
k = meta[3].to_i
a = STDIN.gets().split(" ").sort.reverse
b = STDIN.gets().split(" ").sort.reverse
c = STDIN.gets().split(" ").sort.reverse

ret = Array.new
for ai in 0..a.length - 1
  for bi in 0..b.length - 1
    for ci in 0..c.length - 1
      ret.push a[ai].to_i + b[bi].to_i + c[ci].to_i
    end
  end
end

ret.sort!
ret.reverse!
#p ret

for i in 0..(k - 1)
  puts ret[i]
end
