#include <bits/stdc++.h>
using namespace std;
const int N = 100005;
struct Lemming {
  int w, v, id;
  bool operator<(const Lemming other) const {
    return ((w < other.w) || (w == other.w && v < other.v));
  }
} a[N];
int n, m, h;
int res[N], tres[N];
int main() {
  scanf("%d %d %d", &n, &m, &h);
  for (int i = 0; i < n; i++) scanf("%d ", &a[i].w);
  for (int i = 0; i < n; i++) {
    scanf("%d", &a[i].v);
    a[i].id = i + 1;
  }
  sort(a, a + n);
  double lo = 0.0, hi = 1e9, mid;
  for (int loop = 0; loop <= 100; loop++) {
    mid = (lo + hi) * 0.5;
    int j = 1;
    for (int i = 0; i < n && j <= m; i++)
      if (j * h + 0.0 <= mid * a[i].v) tres[j++] = a[i].id;
    if (j > m) {
      hi = mid;
      memcpy(res, tres, sizeof(int) * (m + 1));
    } else
      lo = mid;
  }
  for (int i = 1; i <= m; i++) printf("%d ", res[i]);
  return 0;
}
