#include <bits/stdc++.h>
using namespace std;
long long check(long long n, long long m, long long x, long long y) {
  return x >= 0 && x < n && y >= 0 && y < m;
}
void pr() { cout << '\n'; }
template <class A, class... B>
void pr(const A &a, const B &...b) {
  cout << a << (sizeof...(b) ? " " : "");
  pr(b...);
}
template <class A>
void PR(A a, long long n) {
  for (long long i = (long long)(0); i < (long long)(n); i++) {
    if (i) cout << ' ';
    cout << a[i];
  }
  cout << '\n';
}
const long long MAX = 1e9 + 7, MAXL = 1LL << 61,
                dx[8] = {-1, 0, 1, 0, -1, -1, 1, 1},
                dy[8] = {0, 1, 0, -1, -1, 1, 1, -1};
class BIT {
 public:
  int n, bit[1000001];
  BIT() { fill(bit, bit + 1000001, 0); }
  void add(int i, int x) {
    while (i <= n) {
      bit[i] += x;
      i += i & -i;
    }
  }
  int sum(int i) {
    int s = 0;
    while (i > 0) {
      s += bit[i];
      i -= i & -i;
    }
    return s;
  }
};
BIT b = BIT();
void Main() {
  b.n = 1000000;
  long long n, T;
  cin >> n >> T;
  for (long long i = (long long)(0); i < (long long)(n); i++) {
    int x;
    cin >> x;
    b.add(x, 1);
  }
  while (T--) {
    int x;
    cin >> x;
    if (x > 0)
      b.add(x, 1);
    else {
      x *= -1;
      long long l = 0, r = 1000000;
      while (l + 1 < r) {
        long long m = (l + r) / 2;
        if (b.sum(m) < x)
          l = m;
        else
          r = m;
      }
      b.add(r, -1);
    }
  }
  for (long long i = (long long)(0); i < (long long)(1000001); i++) {
    if (b.sum(i)) {
      pr(i);
      return;
    }
  }
  pr(0);
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  Main();
  return 0;
}
