#include <bits/stdc++.h>
using namespace std;
template <typename T>
inline const T read1() {
  T m = 0;
  char k = getchar();
  while (('0' > k || k > '9') && (k != '-')) k = getchar();
  const bool f = (k == '-' ? 1 : 0);
  if (f) k = getchar();
  while ('0' <= k && k <= '9')
    m = (m << 3) + (m << 1) + (k ^ 48), k = getchar();
  return f ? -m : m;
}
struct A {
  int x, a, b;
  bool operator<(A y) const {
    return a ^ y.a ? a > y.a : b ^ y.b ? b > y.b : x > y.x;
  }
} a[100002];
int main() {
  int s = read1<int>();
  for (int i = 1; i <= s; ++i) a[i].x = i, a[i].a = read1<int>();
  for (int i = 1; i <= s; ++i) a[i].b = read1<int>();
  sort(a + 1, a + s + 1);
  printf("%d\n", s / 2 + 1);
  for (int i = 0; i <= s; i += 2)
    if (a[i].b > a[i | 1].b)
      printf("%d ", a[i].x);
    else
      printf("%d ", a[i | 1].x);
  return 0;
}
