X, Y, Z, K = gets.split(' ').map(&:to_i)
A = gets.split(' ').map(&:to_i)
B = gets.split(' ').map(&:to_i)
C = gets.split(' ').map(&:to_i)

r_a = A.sort[0, 15]
r_b = B.sort[0, 15]
r_c = C.sort[0, 15]

ret = []
r_a.each do |a|
  r_b.each do |b|
    r_c.each do |c|
      ret << a + b + c
    end
  end
end
ret = ret.sort.reverse

K.times do |i|
  puts ret[i]
end