#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 10;
int n, m;
static char buf[1000000], *p1 = buf, *p2 = buf;
inline int read() {
  register int x = 0;
  register char a =
      p1 == p2 && (p2 = (p1 = buf) + fread(buf, 1, 1000000, stdin), p1 == p2)
          ? EOF
          : *p1++;
  while (a < '0' || a > '9')
    a = p1 == p2 && (p2 = (p1 = buf) + fread(buf, 1, 1000000, stdin), p1 == p2)
            ? EOF
            : *p1++;
  while (a >= '0' && a <= '9')
    x = x * 10 + (a ^ 48),
    a = p1 == p2 && (p2 = (p1 = buf) + fread(buf, 1, 1000000, stdin), p1 == p2)
            ? EOF
            : *p1++;
  return x;
}
struct tree_in_tree {
  int bit[N];
  struct t {
    int ch[2];
    int val;
  } tree[10500000];
  int root[N * 3], num;
  void opt1(int &o, int l, int r, int i, int w) {
    if (o == 0) o = ++num;
    tree[o].val += w;
    if (l == r) return;
    int mid = (l + r) >> 1;
    if (mid >= i)
      opt1(tree[o].ch[0], l, mid, i, w);
    else
      opt1(tree[o].ch[1], mid + 1, r, i, w);
  }
  void add(int pos, int y, int val) {
    if (pos == 0) return;
    for (; pos <= 3 * n + 1; pos += pos & -pos)
      opt1(root[pos], 1, 3 * n + 1, y, val);
  }
  int to2[30][30], num2;
  int opt2(int now, int l, int r, int L, int R) {
    if (R < L) return 0;
    if (l >= L && r <= R) {
      if (n == 1e5) {
      }
      int re = 0;
      for (int i = 1; i <= num2; ++i) re += tree[to2[now][i]].val;
      return re;
    }
    int mid = (l + r) >> 1;
    int ans = 0;
    if (mid >= L) {
      for (int i = 1; i <= num2; ++i) to2[now + 1][i] = tree[to2[now][i]].ch[0];
      ans += opt2(now + 1, l, mid, L, R);
    }
    if (mid < R) {
      for (int i = 1; i <= num2; ++i) to2[now + 1][i] = tree[to2[now][i]].ch[1];
      ans += opt2(now + 1, mid + 1, r, L, R);
    }
    return ans;
  }
  int que(int l, int r, int L, int R) {
    if (r < l) return 0;
    num2 = 0;
    if (r >= 0)
      for (int i = r; i; i -= i & -i) to2[0][++num2] = root[i];
    return opt2(0, 1, 3 * n + 1, L, R);
  }
} t1, t2;
struct dish {
  int p, s, b;
} d[N];
struct person {
  int ids, inc, pref;
} p[N];
int nums[N];
bool pd1(person i, person j) { return i.pref < j.pref; }
bool pd2(dish i, dish j) { return i.s < j.s; }
bool pd3(int i, int j) { return d[i].b < d[j].b; }
int val[N * 3];
int ans[N];
int main() {
  n = read();
  m = read();
  for (int i = 1; i <= n; ++i) {
    nums[i] = i;
    d[i].p = read();
  }
  for (int i = 1; i <= n; ++i) {
    d[i].s = read();
  }
  for (int i = 1; i <= n; ++i) {
    d[i].b = read();
    val[i * 3 - 2] = d[i].s;
    val[i * 3 - 1] = d[i].p + d[i].b;
    val[i * 3] = d[i].p - d[i].b;
  }
  sort(val + 1, val + 1 + 3 * n);
  for (int i = 1; i <= m; ++i) {
    p[i].ids = i;
    p[i].inc = read();
  }
  for (int i = 1; i <= m; ++i) {
    p[i].pref = read();
  }
  sort(p + 1, p + 1 + m, pd1);
  sort(d + 1, d + 1 + n, pd2);
  sort(nums + 1, nums + 1 + n, pd3);
  for (int i = 1; i <= n; ++i) {
    int xx = lower_bound(val + 1, val + 1 + 3 * n, d[i].b + d[i].p) - val;
    int yy = lower_bound(val + 1, val + 1 + 3 * n, d[i].s) - val;
    t1.add(xx, yy, 1);
  }
  int now = 1;
  for (int i = 1; i <= m; ++i) {
    while (now <= n && d[nums[now]].b < p[i].pref) {
      int xx = lower_bound(val + 1, val + 1 + 3 * n,
                           d[nums[now]].p + d[nums[now]].b) -
               val;
      int yy = lower_bound(val + 1, val + 1 + 3 * n, d[nums[now]].s) - val;
      t1.add(xx, yy, -1);
      xx = lower_bound(val + 1, val + 1 + 3 * n,
                       -d[nums[now]].b + d[nums[now]].p) -
           val;
      t2.add(xx, yy, 1);
      ++now;
    }
    int xx =
        lower_bound(val + 1, val + 1 + 3 * n, p[i].inc + p[i].pref + 1) - val;
    --xx;
    int yy = lower_bound(val + 1, val + 1 + 3 * n, p[i].inc) - val;
    ans[p[i].ids] += t1.que(1, xx, yy, 3 * n + 1);
    xx = lower_bound(val + 1, val + 1 + 3 * n, p[i].inc - p[i].pref + 1) - val;
    --xx;
    ans[p[i].ids] += t2.que(1, xx, yy, 3 * n + 1);
  }
  for (int i = 1; i <= m; ++i) printf("%d ", ans[i]);
}
