#include <bits/stdc++.h>
using namespace std;
inline int setBit(int N, int pos) { return N = N | (1 << pos); }
inline int resetBit(int N, int pos) { return N = N & ~(1 << pos); }
inline bool checkBit(int N, int pos) { return (bool)(N & (1 << pos)); }
const int MAX = 200005;
long long n, r, l[MAX], t[MAX], drink, curTime;
vector<long long> taken;
inline double f(long long length, long long t) {
  if (length <= t) {
    curTime += length;
    return 0;
  }
  long long x = max(0ll, length - t);
  long long dc = x / r, i;
  if (x % r != 0) dc++;
  drink += dc;
  curTime += length - x - x;
  double rem = dc * r - x;
  if (drink <= 100000) {
    for (i = 0; i < dc; i++) {
      taken.push_back(curTime + i * r);
    }
  }
  curTime += dc * r;
  return rem;
}
int main() {
  long long i;
  scanf("%lld %lld", &n, &r);
  for (i = 0; i < n; i++) {
    scanf("%lld", &l[i]);
    l[i] += l[i];
  }
  for (i = 0; i < n; i++) {
    scanf("%lld", &t[i]);
    if (t[i] + t[i] < l[i]) {
      puts("-1");
      return 0;
    }
  }
  double rem = 0;
  for (i = 0; i < n; i++) {
    if (l[i] - rem - rem < 0) {
      rem -= l[i] / 2.0;
      continue;
    }
    rem = f(l[i] - rem - rem, t[i] - rem);
    assert(rem == (long long)rem);
  }
  printf("%lld\n", drink);
  if (drink > 100000) return 0;
  for (i = 0; i < drink; i++) cout << taken[i] << " ";
  puts("");
  return 0;
}
