#include <bits/stdc++.h>
using namespace std;
long long n, r;
long long l[200010], t[200010];
long long lsum[200010];
vector<long long> x;
int main() {
  cin >> n >> r;
  for (long long i = (long long)(0); i < (long long)(n); i++) cin >> l[i];
  for (long long i = (long long)(0); i < (long long)(n); i++)
    lsum[i + 1] = l[i] + lsum[i];
  lsum[n + 1] = 1e16;
  for (long long i = (long long)(0); i < (long long)(n); i++) cin >> t[i];
  for (long long i = (long long)(0); i < (long long)(n); i++) {
    if (t[i] < l[i]) {
      cout << -1 << endl;
      return 0;
    }
  }
  for (long long i = (long long)(0); i < (long long)(n); i++) {
    x.push_back(max(0LL, l[i] * 2 - t[i]));
  }
  vector<long long> res;
  long long crtt = 0, crtd = 0;
  long long cnt = 0;
  for (long long i = 0; i < n;) {
    if (x[i] == 0) {
      long long mg = lsum[i + 1] - crtd;
      crtt += 2 * mg;
      crtd += mg;
      i++;
      continue;
    }
    long long mg = l[i] - x[i] - (crtd - lsum[i]);
    crtd += mg;
    crtt += mg * 2LL;
    for (; crtd < lsum[i + 1]; crtd += r, crtt += r) {
      if (res.size() <= 100000) {
        res.push_back(crtt);
        cnt++;
      } else {
        long long y = (lsum[i + 1] - crtd + r - 1) / r;
        cnt += y;
        crtd += y * r;
        crtt += y * r;
        break;
      }
    }
    long long idx = lower_bound(lsum, lsum + n + 1, crtd) - lsum;
    if (idx == n + 1) break;
    idx--;
    x[idx] = max(0LL, x[idx] - (crtd - lsum[idx]));
    i = idx;
  }
  if (cnt <= 100000) {
    cout << res.size() << endl;
    for (long long i = (long long)(0); i < (long long)(res.size()); i++)
      cout << res[i] << " ";
    cout << endl;
  } else {
    cout << cnt << endl;
  }
  return 0;
}
