object Main {

  def main(args: Array[String]): Unit = {
    val X, Y, Z, K = Scanner.nextInt()
    val A = List.fill(X)(Scanner.nextLong())
    val B = List.fill(Y)(Scanner.nextLong())
    val C = List.fill(Z)(Scanner.nextLong())

    val size = Math.min(X * Y, K)
    val AB = (for {
      a <- A
      b <- B
    } yield a + b)
      .sorted(Ordering.Long.reverse)
      .take(size)

    println((for {
      ab <- AB
      c <- C
    } yield ab + c)
      .sorted(Ordering.Long.reverse)
      .take(K)
      .mkString("\n"))
  }

  private[this] object Scanner {
    private[this] val buf = new Array[Byte](1024); private var ptr = 0; private var len = 0
    @inline private[this] def isPrintableChar(c: Int): Boolean = 33 <= c && c <= 126
    @inline private[this] def hasNextByte(): Boolean =
      if (ptr >= len) { ptr = 0; len = System.in.read(buf); len > 0 } else { true }
    @inline private[this] def hasNext(): Boolean = {
      while (hasNextByte() && !isPrintableChar(buf(ptr))) ptr += 1
      hasNextByte()
    }
    @inline private[this] def readByte(): Byte =
      if (hasNextByte()) { val res = buf(ptr); ptr += 1; res } else { -1 }
    def next(): String = {
      if(!hasNext()) ???
      val sb = new StringBuilder; var b = readByte()
      while (isPrintableChar(b)) { sb.append(b.toChar); b = readByte() }
      sb.toString
    }
    def nextInt(): Int = {
      val n = nextLong()
      if (n < Int.MinValue || Int.MaxValue < n) ???
      n.toInt
    }
    def nextLong(): Long = {
      if(!hasNext()) ???
      var minus = false; var b = readByte()
      if (b == '-') { minus = true; b = readByte() }
      def go (b: Byte, n: Long = 0): Long =
        if ('0' <= b && b <= '9') { go(readByte(), n * 10 + b - '0') }
        else if (minus) { -n } else { n }
      go(b)
    }
    def nextDouble(): Double = next.toDouble
  }

}

