#include <bits/stdc++.h>
using namespace std;

int x, y, z, k;
long long a[1000], b[1000], c[1000];

int main() {
  cin >> x >> y >> z >> k;
  for (int i = 0; i < x; ++i) cin >> a[i];
  for (int i = 0; i < y; ++i) cin >> b[i];
  for (int i = 0; i < z; ++i) cin >> c[i];
  
  vector<long long> v;
  for (int i = 0; i < x; ++i) for (int j = 0; j < y; ++j) v.push_back(a[i] + b[j]);
  
  sort(v.rbegin(), v.rend());
  sort(c, c+z), reverse(c, c+z);
  
  vector<long long> w;
  for (int i = 0; i < v.size(); ++i) for (int j = 0; j < z; ++j) if (i * j <= k) {
    w.push_back(v[i] + c[j]);
  }
  
  sort(w.rbegin(), w.rend());
  
  for (int i = 0; i < k; ++i) cout << w[i] << endl;
}