#include <bits/stdc++.h>
#pragma GCC optimize(2, 3, "Ofast")
namespace MyMinMax {
template <typename T>
inline T mn(const T x, const T y) {
  return x < y ? x : y;
}
template <typename T>
inline T mx(const T x, const T y) {
  return x > y ? x : y;
}
template <typename T>
inline bool chmin(T &x, const T y) {
  return (x > y) && ((x = y), 1);
}
template <typename T>
inline bool chmax(T &x, const T y) {
  return (x < y) && ((x = y), 1);
}
template <typename T, typename... Args>
inline T mx(const T x, const Args... args) {
  return mx(x, mx(args...));
}
template <typename T, typename... Args>
inline T mn(const T x, const Args... args) {
  return mn(x, mn(args...));
}
}  // namespace MyMinMax
using namespace MyMinMax;
namespace IO {
const int DPAIRSIZ = 1 << 18;
char BB[DPAIRSIZ], *SS = BB, *TT = BB;
inline char getcha() {
  return SS == TT && (TT = (SS = BB) + fread(BB, 1, DPAIRSIZ, stdin), SS == TT)
             ? EOF
             : *SS++;
}
template <typename T = int>
inline T read() {
  T x = 0;
  int fu = 1;
  char c = getcha();
  while (c < 48) {
    if (c == 45) {
      fu = -1;
    }
    c = getcha();
  }
  while (c >= 48) {
    x = x * 10 + c - 48;
    c = getcha();
  }
  x *= fu;
  return x;
}
template <typename T>
inline void read(T &x) {
  x = 0;
  int fu = 1;
  char c = getcha();
  while (c < 48) {
    if (c == 45) {
      fu = -1;
    }
    c = getcha();
  }
  while (c >= 48) {
    x = x * 10 + c - 48;
    c = getcha();
  }
  x *= fu;
}
template <typename T>
inline void read(T *bg, T *ed) {
  while (bg != ed) read(*bg++);
}
inline void read(char &ch) {
  ch = getcha();
  while (ch <= 32) ch = getcha();
}
inline void read(char *s) {
  char ch = getcha();
  while (ch <= 32) ch = getcha();
  while (ch > 32) *s++ = ch, ch = getcha();
  *s = '\0';
}
inline void getl(char *s) {
  char ch = getcha();
  while (ch < 32) ch = getcha();
  while (ch >= 32) *s++ = ch, ch = getcha();
  *s = '\0';
}
inline void pread(char *&s) {
  char ch = getcha();
  while (ch <= 32) ch = getcha();
  while (ch > 32) *s++ = ch, ch = getcha();
  *s = '\0';
}
inline void pgetl(char *&s) {
  char ch = getcha();
  while (ch <= 32) ch = getcha();
  while (ch > 32) *s++ = ch, ch = getcha();
  *s = '\0';
}
template <typename T, typename... Args>
inline void read(T &x, Args &...args) {
  read(x);
  read(args...);
}
char out[DPAIRSIZ], *Out = out;
inline void putcha(char x) {
  *Out++ = x;
  if (Out - out >= (DPAIRSIZ)) fwrite(out, 1, Out - out, stdout), Out = out;
}
template <typename T>
inline void fprint(T x) {
  if (x < 0) putcha(45), x = -x;
  if (x > 9) fprint(x / 10);
  putcha(x % 10 + 48);
}
inline void print() { putcha(10); }
template <typename T>
inline void print(T x) {
  fprint(x);
  putcha(10);
}
inline void print(char *ch) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(10);
}
inline void put(char *ch) {
  while (*ch != '\0') putcha(*(ch++));
}
inline void print(const char *ch) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(10);
}
inline void put(const char *ch) {
  while (*ch != '\0') putcha(*(ch++));
}
template <typename T, typename... Args>
inline void print(T x, Args... args) {
  fprint(x);
  putcha(32);
  print(args...);
}
template <typename... Args>
inline void print(const char *ch, Args... args) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(32);
  print(args...);
}
template <typename... Args>
inline void print(char *ch, Args... args) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(32);
  print(args...);
}
template <typename T, typename... Args>
inline void printl(T x, Args... args) {
  fprint(x);
  putcha(10);
  printl(args...);
}
template <typename... Args>
inline void printl(const char *ch, Args... args) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(10);
  printl(args...);
}
template <typename... Args>
inline void printl(char *ch, Args... args) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(10);
  printl(args...);
}
template <typename T>
inline void sprint(T x) {
  fprint(x);
  putcha(32);
}
template <typename T, typename... Args>
inline void sprint(T x, Args... args) {
  fprint(x);
  putcha(32);
  sprint(args...);
}
template <typename T>
inline void sprint(T *bg, T *ed) {
  while (bg != ed) sprint(*bg++);
}
template <typename T>
inline void print(T *bg, T *ed) {
  while (bg != ed) sprint(*bg++);
  putcha(10);
}
template <typename T>
inline void printl(T *bg, T *ed) {
  while (bg != ed) print(*bg++);
}
class AutoFlush {
 public:
  ~AutoFlush() { fwrite(out, 1, Out - out, stdout); }
} __AutoFlush;
}  // namespace IO
using namespace IO;
const int INF = 0x3f3f3f3f;
const long long INFll = 0x3f3f3f3f3f3f3f3fll;
const int MAXN = 3e5 + 5;
int n, a[MAXN], b[MAXN];
int f[MAXN], pre[MAXN];
struct Segtree {
  struct Dat {
    int id, val;
    inline Dat operator+(const Dat &b) const { return val < b.val ? *this : b; }
  } t[MAXN << 2];
  inline void pushup(int rt) { t[rt] = t[rt << 1] + t[rt << 1 | 1]; }
  void build(int rt, int l, int r) {
    if (l == r) {
      t[rt] = (Dat){l, f[l]};
      return;
    }
    int mid = (l + r) >> 1;
    build(rt << 1, l, mid);
    build(rt << 1 | 1, mid + 1, r);
    pushup(rt);
  }
  void modify(int rt, int l, int r, int x) {
    if (l == r) {
      t[rt] = (Dat){l, f[l]};
      return;
    }
    int mid = (l + r) >> 1;
    x <= mid ? modify(rt << 1, l, mid, x) : modify(rt << 1 | 1, mid + 1, r, x);
    pushup(rt);
  }
  Dat query(int rt, int l, int r, int x, int y) {
    if (x <= l && r <= y) return t[rt];
    int mid = (l + r) >> 1;
    if (x > mid) return query(rt << 1 | 1, mid + 1, r, x, y);
    if (y <= mid) return query(rt << 1, l, mid, x, y);
    return query(rt << 1, l, mid, x, y) + query(rt << 1 | 1, mid + 1, r, x, y);
  }
} t;
std::vector<int> in[MAXN];
int stk[MAXN], tp, p[MAXN];
signed main() {
  read(n);
  read(a + 1, a + n + 1);
  read(b + 1, b + n + 1);
  for (int i = (1), iEND = (n); i <= iEND; ++i)
    f[i] = INF, in[i + b[i]].push_back(i), pre[i] = -1, p[i] = i;
  std::sort(p + 1, p + n + 1, [](int x, int y) { return x - a[x] < y - a[y]; });
  t.build(1, 0, n);
  for (int k = (1), kEND = (n); k <= kEND; ++k) {
    const int i = p[k];
    const Segtree::Dat x = t.query(1, 0, n, mx(0, i - a[i]), i);
    if (x.val == INF) continue;
    for (auto it : in[i]) {
      pre[it] = x.id;
      f[it] = x.val + 1;
      t.modify(1, 0, n, it);
    }
  }
  int x = n;
  do {
    if (pre[x] == -1) return print("-1"), 0;
    x = pre[x];
    stk[++tp] = x;
  } while (x);
  print(tp);
  print(stk + 1, stk + tp + 1);
}

### Prompt

Please create a solution in CPP to the following problem:

Frog Gorf is traveling through Swamp kingdom. Unfortunately, after a poor jump, he fell into a well of n meters depth. Now Gorf is on the bottom of the well and has a long way up.

The surface of the well's walls vary in quality: somewhere they are slippery, but somewhere have convenient ledges. In other words, if Gorf is on x meters below ground level, then in one jump he can go up on any integer distance from 0 to a_x meters inclusive. (Note that Gorf can't jump down, only up).

Unfortunately, Gorf has to take a break after each jump (including jump on 0 meters). And after jumping up to position x meters below ground level, he'll slip exactly b_x meters down while resting.

Calculate the minimum number of jumps Gorf needs to reach ground level.

Input

The first line contains a single integer n (1 ≤ n ≤ 300 000) — the depth of the well.

The second line contains n integers a_1, a_2, …, a_n (0 ≤ a_i ≤ i), where a_i is the maximum height Gorf can jump from i meters below ground level.

The third line contains n integers b_1, b_2, …, b_n (0 ≤ b_i ≤ n - i), where b_i is the distance Gorf will slip down if he takes a break on i meters below ground level.

Output

If Gorf can't reach ground level, print -1. Otherwise, firstly print integer k — the minimum possible number of jumps.

Then print the sequence d_1,\,d_2, …,\,d_k where d_j is the depth Gorf'll reach after the j-th jump, but before he'll slip down during the break. Ground level is equal to 0.

If there are multiple answers, print any of them.

Examples

Input


3
0 2 2
1 1 0


Output


2
1 0 


Input


2
1 1
1 0


Output


-1


Input


10
0 1 2 3 5 5 6 7 8 5
9 8 7 1 5 4 3 2 0 0


Output


3
9 4 0 

Note

In the first example, Gorf is on the bottom of the well and jump to the height 1 meter below ground level. After that he slip down by meter and stays on height 2 meters below ground level. Now, from here, he can reach ground level in one jump.

In the second example, Gorf can jump to one meter below ground level, but will slip down back to the bottom of the well. That's why he can't reach ground level.

In the third example, Gorf can reach ground level only from the height 5 meters below the ground level. And Gorf can reach this height using a series of jumps 10 ⇒ 9 \dashrightarrow 9 ⇒ 4 \dashrightarrow 5 where ⇒ is the jump and \dashrightarrow is slipping during breaks.

### Response

```cpp
#include <bits/stdc++.h>
#pragma GCC optimize(2, 3, "Ofast")
namespace MyMinMax {
template <typename T>
inline T mn(const T x, const T y) {
  return x < y ? x : y;
}
template <typename T>
inline T mx(const T x, const T y) {
  return x > y ? x : y;
}
template <typename T>
inline bool chmin(T &x, const T y) {
  return (x > y) && ((x = y), 1);
}
template <typename T>
inline bool chmax(T &x, const T y) {
  return (x < y) && ((x = y), 1);
}
template <typename T, typename... Args>
inline T mx(const T x, const Args... args) {
  return mx(x, mx(args...));
}
template <typename T, typename... Args>
inline T mn(const T x, const Args... args) {
  return mn(x, mn(args...));
}
}  // namespace MyMinMax
using namespace MyMinMax;
namespace IO {
const int DPAIRSIZ = 1 << 18;
char BB[DPAIRSIZ], *SS = BB, *TT = BB;
inline char getcha() {
  return SS == TT && (TT = (SS = BB) + fread(BB, 1, DPAIRSIZ, stdin), SS == TT)
             ? EOF
             : *SS++;
}
template <typename T = int>
inline T read() {
  T x = 0;
  int fu = 1;
  char c = getcha();
  while (c < 48) {
    if (c == 45) {
      fu = -1;
    }
    c = getcha();
  }
  while (c >= 48) {
    x = x * 10 + c - 48;
    c = getcha();
  }
  x *= fu;
  return x;
}
template <typename T>
inline void read(T &x) {
  x = 0;
  int fu = 1;
  char c = getcha();
  while (c < 48) {
    if (c == 45) {
      fu = -1;
    }
    c = getcha();
  }
  while (c >= 48) {
    x = x * 10 + c - 48;
    c = getcha();
  }
  x *= fu;
}
template <typename T>
inline void read(T *bg, T *ed) {
  while (bg != ed) read(*bg++);
}
inline void read(char &ch) {
  ch = getcha();
  while (ch <= 32) ch = getcha();
}
inline void read(char *s) {
  char ch = getcha();
  while (ch <= 32) ch = getcha();
  while (ch > 32) *s++ = ch, ch = getcha();
  *s = '\0';
}
inline void getl(char *s) {
  char ch = getcha();
  while (ch < 32) ch = getcha();
  while (ch >= 32) *s++ = ch, ch = getcha();
  *s = '\0';
}
inline void pread(char *&s) {
  char ch = getcha();
  while (ch <= 32) ch = getcha();
  while (ch > 32) *s++ = ch, ch = getcha();
  *s = '\0';
}
inline void pgetl(char *&s) {
  char ch = getcha();
  while (ch <= 32) ch = getcha();
  while (ch > 32) *s++ = ch, ch = getcha();
  *s = '\0';
}
template <typename T, typename... Args>
inline void read(T &x, Args &...args) {
  read(x);
  read(args...);
}
char out[DPAIRSIZ], *Out = out;
inline void putcha(char x) {
  *Out++ = x;
  if (Out - out >= (DPAIRSIZ)) fwrite(out, 1, Out - out, stdout), Out = out;
}
template <typename T>
inline void fprint(T x) {
  if (x < 0) putcha(45), x = -x;
  if (x > 9) fprint(x / 10);
  putcha(x % 10 + 48);
}
inline void print() { putcha(10); }
template <typename T>
inline void print(T x) {
  fprint(x);
  putcha(10);
}
inline void print(char *ch) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(10);
}
inline void put(char *ch) {
  while (*ch != '\0') putcha(*(ch++));
}
inline void print(const char *ch) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(10);
}
inline void put(const char *ch) {
  while (*ch != '\0') putcha(*(ch++));
}
template <typename T, typename... Args>
inline void print(T x, Args... args) {
  fprint(x);
  putcha(32);
  print(args...);
}
template <typename... Args>
inline void print(const char *ch, Args... args) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(32);
  print(args...);
}
template <typename... Args>
inline void print(char *ch, Args... args) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(32);
  print(args...);
}
template <typename T, typename... Args>
inline void printl(T x, Args... args) {
  fprint(x);
  putcha(10);
  printl(args...);
}
template <typename... Args>
inline void printl(const char *ch, Args... args) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(10);
  printl(args...);
}
template <typename... Args>
inline void printl(char *ch, Args... args) {
  while (*ch != '\0') putcha(*(ch++));
  putcha(10);
  printl(args...);
}
template <typename T>
inline void sprint(T x) {
  fprint(x);
  putcha(32);
}
template <typename T, typename... Args>
inline void sprint(T x, Args... args) {
  fprint(x);
  putcha(32);
  sprint(args...);
}
template <typename T>
inline void sprint(T *bg, T *ed) {
  while (bg != ed) sprint(*bg++);
}
template <typename T>
inline void print(T *bg, T *ed) {
  while (bg != ed) sprint(*bg++);
  putcha(10);
}
template <typename T>
inline void printl(T *bg, T *ed) {
  while (bg != ed) print(*bg++);
}
class AutoFlush {
 public:
  ~AutoFlush() { fwrite(out, 1, Out - out, stdout); }
} __AutoFlush;
}  // namespace IO
using namespace IO;
const int INF = 0x3f3f3f3f;
const long long INFll = 0x3f3f3f3f3f3f3f3fll;
const int MAXN = 3e5 + 5;
int n, a[MAXN], b[MAXN];
int f[MAXN], pre[MAXN];
struct Segtree {
  struct Dat {
    int id, val;
    inline Dat operator+(const Dat &b) const { return val < b.val ? *this : b; }
  } t[MAXN << 2];
  inline void pushup(int rt) { t[rt] = t[rt << 1] + t[rt << 1 | 1]; }
  void build(int rt, int l, int r) {
    if (l == r) {
      t[rt] = (Dat){l, f[l]};
      return;
    }
    int mid = (l + r) >> 1;
    build(rt << 1, l, mid);
    build(rt << 1 | 1, mid + 1, r);
    pushup(rt);
  }
  void modify(int rt, int l, int r, int x) {
    if (l == r) {
      t[rt] = (Dat){l, f[l]};
      return;
    }
    int mid = (l + r) >> 1;
    x <= mid ? modify(rt << 1, l, mid, x) : modify(rt << 1 | 1, mid + 1, r, x);
    pushup(rt);
  }
  Dat query(int rt, int l, int r, int x, int y) {
    if (x <= l && r <= y) return t[rt];
    int mid = (l + r) >> 1;
    if (x > mid) return query(rt << 1 | 1, mid + 1, r, x, y);
    if (y <= mid) return query(rt << 1, l, mid, x, y);
    return query(rt << 1, l, mid, x, y) + query(rt << 1 | 1, mid + 1, r, x, y);
  }
} t;
std::vector<int> in[MAXN];
int stk[MAXN], tp, p[MAXN];
signed main() {
  read(n);
  read(a + 1, a + n + 1);
  read(b + 1, b + n + 1);
  for (int i = (1), iEND = (n); i <= iEND; ++i)
    f[i] = INF, in[i + b[i]].push_back(i), pre[i] = -1, p[i] = i;
  std::sort(p + 1, p + n + 1, [](int x, int y) { return x - a[x] < y - a[y]; });
  t.build(1, 0, n);
  for (int k = (1), kEND = (n); k <= kEND; ++k) {
    const int i = p[k];
    const Segtree::Dat x = t.query(1, 0, n, mx(0, i - a[i]), i);
    if (x.val == INF) continue;
    for (auto it : in[i]) {
      pre[it] = x.id;
      f[it] = x.val + 1;
      t.modify(1, 0, n, it);
    }
  }
  int x = n;
  do {
    if (pre[x] == -1) return print("-1"), 0;
    x = pre[x];
    stk[++tp] = x;
  } while (x);
  print(tp);
  print(stk + 1, stk + tp + 1);
}

```