#include <bits/stdc++.h>
using namespace std;
void ac(long long x) {
  if (x)
    puts("YES");
  else
    puts("NO");
}
long long gcd(long long a, long long b) { return b == 0 ? a : gcd(b, a % b); }
long long ppow(long long a, long long b, long long mod) {
  a %= mod;
  long long ans = 1 % mod;
  while (b) {
    if (b & 1) ans = (long long)ans * a % mod;
    a = (long long)a * a % mod;
    b >>= 1;
  }
  return ans;
}
long long readdd() {
  long long x = 0, f = 1;
  char c = getchar();
  while (!isdigit(c) && c != '-') c = getchar();
  if (c == '-') f = -1, c = getchar();
  while (isdigit(c)) x = x * 10 + c - '0', c = getchar();
  return f * x;
}
void printtt(long long x) {
  if (x < 0) putchar('-'), x = -x;
  if (x >= 10) printtt(x / 10);
  putchar(x % 10 + '0');
}
bool addd(long long a, long long b) { return a > b; }
long long lowbit(long long x) { return x & -x; }
const long long dx[4] = {0, 0, 1, -1};
const long long dy[4] = {1, -1, 0, 0};
const long long BN = 1e6 + 5;
struct BIT {
  long long c[BN];
  void init() { memset(c, 0, sizeof c); }
  long long lowbit(long long i) { return i & -i; }
  void add(long long i, long long t) {
    while (i < BN) c[i] += t, i += lowbit(i);
  }
  long long ask(long long i) {
    long long ans = 0;
    while (i) ans += c[i], i -= lowbit(i);
    return ans;
  }
};
bool Isprime(long long x) {
  for (long long i = 2; i * i <= x; i++)
    if (x % i == 0) return 0;
  return 1;
}
void init() { ; }
const double eps = 1e-6;
const long long mod = 1e9 + 7;
const long long modd = mod - 1;
const long long maxm = 1e6 + 5;
BIT T;
void solve() {
  long long n = readdd(), q = readdd();
  for (signed long long(i) = 1; (i) <= (n); (i)++) {
    long long x = readdd();
    T.add(x, 1);
  }
  for (signed long long(i) = 1; (i) <= (q); (i)++) {
    long long x = readdd();
    if (x >= 1 && x <= n) {
      T.add(x, 1);
    } else {
      x = -x;
      long long l = 1, r = n;
      long long ans = -1;
      while (l <= r) {
        long long mid = (l + r) / 2;
        if (T.ask(mid) >= x) {
          ans = mid, r = mid - 1;
        } else {
          l = mid + 1;
        }
      }
      if (ans != -1) {
        T.add(ans, -1);
      }
    }
  }
  for (long long i = 1; i <= n; i++) {
    if (T.ask(i) - T.ask(i - 1)) {
      printtt(i);
      return;
    }
  }
  printtt(0);
}
signed main() {
  init();
  solve();
  return 0;
}
