#include <bits/stdc++.h>
using namespace std;
const int MAXN = 1000000;
const int MOD = 1000000007;
const int INF = ((1 << 31) - 1);
class cesta {
 public:
  long long first, second;
  int ind;
};
bool cmp(cesta a, cesta b) {
  return a.second != b.second ? a.second < b.second
         : a.first != b.first ? a.first < b.first
                              : a.ind < b.ind;
}
long long n, m, px, py;
cesta p[MAXN + 5];
int pos;
int sol[MAXN + 5];
set<pair<long long, long long> > s;
int main() {
  scanf("%I64d%I64d", &n, &m);
  scanf("%I64d%I64d", &px, &py);
  n--;
  for (int i = (0), _for = (n); i < _for; ++i) {
    long long first, second;
    scanf("%I64d%I64d", &first, &second);
    p[i].first = first - py;
    p[i].second = second - px;
    p[i].ind = i;
    px = first;
    py = second;
  }
  sort(p, p + n, cmp);
  for (int i = (0), _for = (m); i < _for; ++i) {
    long long first;
    scanf("%I64d", &first);
    s.insert(make_pair(first, i));
  }
  for (int i = (0), _for = (n); i < _for; ++i) {
    set<pair<long long, long long> >::iterator it;
    it = s.lower_bound(make_pair(p[i].first, -1));
    if ((it == s.end()) || ((it->first) > p[i].second)) {
      printf("No");
      return 0;
    }
    sol[p[i].ind] = it->second;
    s.erase(it);
  }
  printf("Yes\n");
  for (int i = (0), _for = (n); i < _for; ++i) printf("%d ", sol[i] + 1);
  return 0;
}
