class PQ
  def initialize(&block)
    @heap = [nil]
    @cmp = block || lambda{|x, y| x <=> y}
  end

  def empty?
    @heap.size == 1
  end

  def insert(value)
    @heap.push(value)
    up_heap
  end

  def bulk_insert(values)
    values.each{|value| insert(value)}
  end
  
  def up_heap(k = @heap.size - 1)
    while true
      return if k == 1

      parent = k / 2
      if @cmp.(@heap[parent], @heap[k]) == -1
        @heap[parent], @heap[k] = @heap[k], @heap[parent]
        k = parent
      else
        return
      end
    end
  end

  def top
    @heap[1]
  end

  def pop
    if empty?
      nil
    elsif @heap.size == 2
      @heap.pop
    else
      value = @heap[1]
      @heap[1] = @heap.pop
      down_heap
      value
    end
  end

  def down_heap(k = 1)
    loop do
      child1 = 2 * k
      child2 = 2 * k + 1
      if @cmp.(child1, @heap.size)  >= 0
        return
      elsif @cmp.(child2, @heap.size)  >= 0
        large_child = child1
      else
        large_child = (@cmp.(@heap[child1], @heap[child2]) > 0) ? child1 : child2
      end

      if @cmp.(@heap[large_child], @heap[k]) > 0
        @heap[large_child], @heap[k] = @heap[k], @heap[large_child]
        k = large_child
      else
        return
      end
    end
  end
end


require 'set'

def value(t)
  $a[t[0]] + $b[t[1]] + $c[t[2]]
end

def main
  x, y, z, k = gets.split(/\s+/).map(&:to_i)
  $a = gets.split(/\s+/).map(&:to_i)
  $b = gets.split(/\s+/).map(&:to_i)
  $c = gets.split(/\s+/).map(&:to_i)

  $a.sort!
  $b.sort!
  $c.sort!

  done = Set.new
  q = PQ.new
  t = [x - 1, y - 1, z - 1]
  q.insert([value(t), t])

  k.times do
    value, t = q.pop
    puts value
    t1 = [t[0] - 1, t[1], t[2]]
    t2 = [t[0], t[1] - 1, t[2]]
    t3 = [t[0], t[1], t[2] - 1]
    if !done.member?(t1) && t[0] - 1 >= 0
      q.insert([value(t1), t1])
      done.add(t1)
    end
    if !done.member?(t2) && t[1] - 1 >= 0
      q.insert([value(t2), t2])
      done.add(t2)
    end
    if !done.member?(t3) && t[2] - 1 >= 0
      q.insert([value(t3), t3])
      done.add(t3)
    end

  end
end

main
