#include <bits/stdc++.h>
static const int MAXN = 102;
int n, k;
int a[MAXN], b[MAXN];
int p[MAXN], r[MAXN];
inline bool check() {
  for (int i = 1; i < n; ++i)
    if (r[i] <= r[i - 1]) return true;
  return false;
}
int main() {
  scanf("%d%d", &n, &k);
  int last_zero = -1;
  for (int i = 0; i < n; ++i) {
    scanf("%d", &a[i]);
    if (a[i] == 0) last_zero = i;
  }
  for (int i = 0; i < k; ++i) scanf("%d", &b[i]);
  bool valid = false;
  for (int i = 0; i < k; ++i) p[i] = i;
  do {
    for (int i = 0, ptr = 0; i < n; ++i) {
      r[i] = (a[i] == 0) ? b[p[ptr++]] : a[i];
    }
    if (check()) {
      valid = true;
      break;
    }
  } while (std::next_permutation(p, p + k));
  puts(valid ? "Yes" : "No");
  return 0;
}
