import core.bitop;
import std.algorithm;
import std.ascii;
import std.bigint;
import std.conv;
import std.functional;
import std.math;
import std.numeric;
import std.range;
import std.stdio;
import std.string;
import std.random;
import std.typecons;
import std.container;

alias sread = () => readln.chomp();
alias Point2 = Tuple!(long, "y", long, "x");

T lread(T = long)()
{
    return readln.chomp.to!T();
}

T[] aryread(T = long)()
{
    return readln.split.to!(T[])();
}

void scan(TList...)(ref TList Args)
{
    auto line = readln.split();
    foreach (i, T; TList)
    {
        T val = line[i].to!(T);
        Args[i] = val;
    }
}

void minAssign(T, U = T)(ref T dst, U src)
{
    dst = cast(T) min(dst, src);
}

enum MOD = 10 ^^ 9 + 7;

void main()
{
    long X, Y, Z, K;
    scan(X, Y, Z, K);
    auto A = aryread();
    auto B = aryread();
    auto C = aryread();
    A.sort!"b<a"();
    B.sort!"b<a"();
    C.sort!"b<a"();
    bool f(long[3] a, long[3] b)
    {
        return A[a[0]] + B[a[1]] + C[a[2]] < A[b[0]] + B[b[1]] + C[b[2]];
    }

    BinaryHeap!(long[3][], f) priority_queue = BinaryHeap!(long[3][], f)(new long[3][K * 3], 0);
    priority_queue.insert([0, 0, 0]);
    // writeln(priority_queue);
    // while (priority_queue.length < K)
    bool[Tuple!(long, long, long)] S;
    S[tuple(0L, 0L, 0L)] = true;
    foreach (_; 0 .. K)
    {
        auto x = priority_queue.front;
        writeln(A[x[0]] + B[x[1]] + C[x[2]]);
        priority_queue.removeFront();
        if (x[0] + 1 < X && !(tuple(x[0] + 1, x[1], x[2]) in S))
        {
            S[tuple(x[0] + 1, x[1], x[2])] = true;
            priority_queue.insert([x[0] + 1, x[1], x[2]]);
        }
        if (x[1] + 1 < Y && !(tuple(x[0], x[1] + 1, x[2]) in S))
        {
            S[tuple(x[0], x[1] + 1, x[2])] = true;
            priority_queue.insert([x[0], x[1] + 1, x[2]]);
        }
        if (x[2] + 1 < Z && !(tuple(x[0], x[1], x[2] + 1) in S))
        {
            S[tuple(x[0], x[1], x[2] + 1)] = true;
            priority_queue.insert([x[0], x[1], x[2] + 1]);
        }
    }
}
