#include <bits/stdc++.h>
using namespace std;
vector<long long> s(320000, 0), init(320000, 0);
long long dp[320000];
long long calc(long long i, long long j) { return s[j] - s[i - 1]; }
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  cout.tie(nullptr);
  cerr.tie(nullptr);
  long long n;
  cin >> n;
  map<long long, long long> m;
  vector<long long> a(n + 1);
  for (long long i = 1; i <= n; ++i) {
    cin >> a[i];
    m[a[i]] = i;
  }
  sort(a.begin() + 1, a.end());
  for (long long i = 1; i <= n; ++i) s[i] = s[i - 1] + a[i];
  long long k;
  cin >> k;
  init[1] = 0;
  for (long long i = 2; i <= k; ++i) {
    init[i] = init[i - 1] + a[i] * (i - 1) - calc(1, i - 1);
  }
  dp[1] = init[k];
  long long res = dp[1], sol = 1;
  for (long long i = 2; i <= n; ++i) {
    if (i + k - 1 > n) break;
    dp[i] = dp[i - 1] - (calc(i, i + k - 2) - (k - 1) * a[i - 1]) +
            ((k - 1) * a[i + k - 1] - calc(i, i + k - 2));
    if (dp[i] < res) {
      res = dp[i];
      sol = i;
    }
  }
  for (long long i = sol; i < sol + k; ++i) cout << m[a[i]] << ' ';
  cout << '\n';
}
