#include <bits/stdc++.h>
using namespace std;
struct Lem {
  int m, v, id;
};
bool operator<(Lem a, Lem b) {
  if (a.m != b.m) return a.m < b.m;
  return a.v < b.v;
}
int n, k, h;
vector<Lem> ls;
vector<int> ans, saved;
int j;
bool can(long double t) {
  ans.clear();
  j = 0;
  for (int i = 1; i <= k; i++) {
    for (; j < n && i * h > ls[j].v * t; j++)
      ;
    if (j == n) return false;
    ans.push_back(ls[j].id);
    j++;
  }
  return true;
}
int main() {
  cin >> n >> k >> h;
  ls.resize(n);
  for (int i = 0; i < n; i++) {
    cin >> ls[i].m;
    ls[i].id = i;
  }
  for (int i = 0; i < n; i++) cin >> ls[i].v;
  sort(ls.begin(), ls.end());
  long double left = 0, right = 1000000000;
  for (int cnt = 0; cnt < 100; cnt++) {
    long double middle = (left + right) / 2;
    if (can(middle)) {
      right = middle;
      saved = ans;
    } else
      left = middle;
  }
  for (size_t i = 0; i < saved.size(); i++) {
    if (i) cout << ' ';
    cout << saved[i] + 1;
  }
  cout << '\n';
  return 0;
}
