#include <bits/stdc++.h>
using namespace std;
struct Num {
  int indx, a, b;
  Num() {}
  Num(int a, int b, int indx) : a(a), b(b), indx(indx) {}
  bool operator<(const Num& other) const { return a > other.a; }
};
Num num[1000001];
int main() {
  int N;
  cin >> N;
  for (int i = 0; i < N; i++) {
    cin >> num[i].a;
    num[i].indx = i + 1;
  }
  for (int i = 0; i < N; i++) cin >> num[i].b;
  sort(num, num + N);
  vector<int> ans;
  ans.push_back(num[0].indx);
  for (int i = 1; i < N - 1; i += 2) {
    if (num[i].b < num[i + 1].b) {
      ans.push_back(num[i + 1].indx);
    } else {
      ans.push_back(num[i].indx);
    }
  }
  if (N % 2 == 0) {
    ans.push_back(num[N - 1].indx);
  }
  cout << ans.size() << "\n";
  for (int i = 0; i < ans.size(); i++) {
    cout << ans[i] << " ";
  }
  return 0;
}
