#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e6 + 7;
int a[maxn];
int k[maxn];
int n, q;
bool judge(int num) {
  int cnt = 0;
  for (int i = 1; i <= n; i++) {
    if (a[i] <= num) cnt++;
  }
  for (int i = 1; i <= q; i++) {
    if (k[i] < 0) {
      if (-k[i] <= cnt) cnt--;
    } else {
      if (k[i] <= num) cnt++;
    }
  }
  return cnt > 0;
}
int main() {
  scanf("%d%d", &n, &q);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &a[i]);
  }
  for (int i = 1; i <= q; i++) {
    scanf("%d", &k[i]);
  }
  if (!judge(n + 1)) {
    printf("0\n");
    return 0;
  }
  int left = 1;
  int right = n;
  while (left <= right) {
    int mid = (left + right) >> 1;
    if (judge(mid))
      right = mid - 1;
    else
      left = mid + 1;
  }
  printf("%d\n", right + 1);
}
