#include <bits/stdc++.h>
using namespace std;
int n;
int A[100000], B[100000], ok[100000], ok2[100000];
void vai(int* kk) {
  int qtdPior = 2000000000;
  int acu = 0;
  for (int i = 0; i < n; i++) {
    acu += A[i] - B[i];
    qtdPior = min(qtdPior, acu);
  }
  acu = 0;
  for (int i = 0; i < n; i++) {
    if (acu + qtdPior >= 0) kk[i] = 1;
    acu += B[i] - A[i];
  }
}
int main() {
  scanf("%d", &n);
  memset(ok, 0, sizeof(ok));
  memset(ok2, 0, sizeof(ok2));
  for (int i = 0; i < n; i++) {
    scanf("%d", A + i);
  }
  for (int i = 0; i < n; i++) {
    scanf("%d", B + i);
  }
  vai(ok);
  reverse(A, A + n);
  reverse(B, B + n);
  int aux = B[0];
  for (int i = 0; i < n - 1; i++) {
    B[i] = B[i + 1];
  }
  B[n - 1] = aux;
  vai(ok2);
  int ans = 0;
  for (int i = 0; i < n; i++) {
    if (ok[i] || ok2[n - i - 1]) ans++;
  }
  printf("%d\n", ans);
  if (ans) {
    for (int i = 0; i < n; i++) {
      if (ok[i] || ok2[n - i - 1]) printf("%d ", i + 1);
    }
    printf("\n");
  }
  return 0;
}
