X, Y, Z, K = gets.split(' ').map(&:to_i)
score = []
score2 = []

a = gets.split(' ').map(&:to_i).sort.reverse
b = gets.split(' ').map(&:to_i).sort.reverse
c = gets.split(' ').map(&:to_i).sort.reverse

a.each do |i|
  b.each do |j|
    score.push(i + j)
  end
end

score = score.sort.reverse

score.slice(0..K).each do |i|
  c.each do |j|
    score2.push(i + j)
  end
end

score2 = score2.sort.reverse

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