#include <bits/stdc++.h>
using namespace std;
const int N = 1e6;
long long num[N];
long long n, m, k, bridge;
long long ans, cnt, res;
set<pair<long long, long long> > va, vb;
struct node {
  long long left, right, id;
  long long lower, upper;
  bool operator<(const node &a) const { return upper < a.upper; }
} mao[N];
int main() {
  while (scanf("%I64d%I64d", &n, &m) != EOF) {
    for (int i = 1; i <= n; ++i) {
      scanf("%I64d%I64d", &mao[i].left, &mao[i].right);
    }
    for (int i = 1; i <= n - 1; ++i) {
      mao[i].id = i;
      mao[i].lower = mao[i + 1].left - mao[i].right;
      mao[i].upper = mao[i + 1].right - mao[i].left;
    }
    sort(mao + 1, mao + n);
    for (int i = 1; i <= m; ++i) {
      scanf("%I64d", &bridge);
      va.insert(make_pair(bridge, i));
    }
    for (int i = 1; i <= n - 1; ++i) {
      set<pair<long long, long long> >::iterator it =
          va.lower_bound((make_pair(mao[i].lower, 0)));
      if (it == va.end()) {
        puts("No");
        return 0;
      } else {
        if (it->first <= mao[i].upper) {
          num[mao[i].id] = it->second;
          va.erase(it);
        } else {
          puts("No");
          return 0;
        }
      }
    }
    puts("Yes");
    printf("%I64d", num[1]);
    for (int i = 2; i <= n - 1; ++i) printf(" %I64d", num[i]);
    puts("");
  }
  return 0;
}
