using System;
using System.Linq;
using System.Collections.Generic;
using static System.Console;
using System.Text;
using System.IO;
using static System.Math;
using System.Numerics;
using System.Runtime.InteropServices.ComTypes;
using System.Xml.Schema;
using System.ComponentModel.DataAnnotations;
using System.Security.Cryptography;

namespace AtCoder
{
    public class Program
    {
        public static void Main(string[] args)
        {
            SetOut(new StreamWriter(OpenStandardOutput()) { AutoFlush = false });
            Solve();
            Out.Flush();
            Read();
        }

        static void Solve()
        {
            var (X, Y, Z, K) = Slice4<long>();
            var Ai = Sarray(); Array.Sort(Ai); Array.Reverse(Ai);
            var Bi = Sarray(); Array.Sort(Bi); Array.Reverse(Bi);
            var Ci = Sarray(); Array.Sort(Ci); Array.Reverse(Ci);
            var hs = new HashSet<(long idxA, long idxB, long idxC)>();
            var pq = new priority_queue<(long v, long idxA, long idxB, long idxC)>((l, r) => l.v.CompareTo(r.v));
            hs.Add((0, 0, 0));
            pq.insert((Ai[0] + Bi[0] + Ci[0], 0, 0, 0));
            for (var i = 0; i < K; ++i)
            {
                var q = pq.extract();
                WriteLine(q.v);
                foreach (var idx in new List<(long a, long b, long c)> { (1, 0, 0), (0, 1, 0), (0, 0, 1) })
                {
                    var (idxA, idxB, idxC) = (q.idxA + idx.a, q.idxB + idx.b, q.idxC + idx.c);
                    if (X <= idxA || Y <= idxB || Z <= idxC) continue;
                    if (!hs.Contains((idxA, idxB, idxC)))
                    {
                        hs.Add((idxA, idxB, idxC));
                        pq.insert((Ai[idxA] + Bi[idxB] + Ci[idxC], idxA, idxB, idxC));
                    }
                }
            }
        }
        class priority_queue<T>
        {
            Comparison<T> cmp;
            T[] A = new T[2000000];
            // var pq = new priority_queue<long>((l, r) => l.CompareTo(r));
            // とすれば値の大きいものから優先
            public priority_queue(Comparison<T> c)
            {
                cmp = c;
            }
            public int num { get; private set; } = 0;
            public void insert(T v)
            {
                A[num] = v;
                ++num;
                increaseKey(num);
            }
            void increaseKey(int i)
            {
                while (1 < i && 0 < cmp(A[i - 1], A[i / 2 - 1]))
                {
                    var t = A[i - 1];
                    A[i - 1] = A[i / 2 - 1];
                    A[i / 2 - 1] = t;
                    i = i / 2;
                }
            }
            public T extract()
            {
                if (num < 1) return default(T);
                var max = A[0];
                A[0] = A[num - 1];
                --num;
                maxHeapify(1);
                return max;
            }
            void maxHeapify(int i)
            {
                var H = num;
                var l = left(i);
                var r = right(i);
                var largest = 0;
                if (l <= H && 0 < cmp(A[l - 1], A[i - 1])) { largest = l; } else { largest = i; }
                if (r <= H && 0 < cmp(A[r - 1], A[largest - 1])) { largest = r; }
                if (largest != i)
                {
                    var t = A[i - 1];
                    A[i - 1] = A[largest - 1];
                    A[largest - 1] = t;
                    maxHeapify(largest);
                }
            }
            int left(int l) => l * 2;
            int right(int r) => r * 2 + 1;
        }

        static long Mod = (long)1e9 + 7;
        static public long[] Sarray() { return ReadLine().Split().Select(long.Parse).ToArray(); }
        static public List<long> Slist() { return ReadLine().Split().Select(long.Parse).ToList(); }
        static public (T1 a, T2 b) Slice<T1, T2>()
        {
            var t = ReadLine().Split();
            return (
            (T1)Convert.ChangeType(t[0], typeof(T1)),
            (T2)Convert.ChangeType(t[1], typeof(T2)));
        }
        static public (T a, T b) Slice2<T>()
        {
            var t = ReadLine().Split();
            return (
            (T)Convert.ChangeType(t[0], typeof(T)),
            (T)Convert.ChangeType(t[1], typeof(T)));
        }
        static public (T a, T b, T c) Slice3<T>()
        {
            var t = ReadLine().Split();
            return (
            (T)Convert.ChangeType(t[0], typeof(T)),
            (T)Convert.ChangeType(t[1], typeof(T)),
            (T)Convert.ChangeType(t[2], typeof(T)));
        }
        static public (T a, T b, T c, T d) Slice4<T>()
        {
            var t = ReadLine().Split();
            return (
            (T)Convert.ChangeType(t[0], typeof(T)),
            (T)Convert.ChangeType(t[1], typeof(T)),
            (T)Convert.ChangeType(t[2], typeof(T)),
            (T)Convert.ChangeType(t[3], typeof(T)));
        }
    }
}

Measured memory_bytes: 30364