#include <bits/stdc++.h>
using namespace std;
int main() {
  int k, l, n, m, q, h, kol = 0;
  cin >> n >> m;
  vector<int> v, u, r;
  for (int i = 0; i < n; i++) {
    cin >> k;
    v.push_back(k);
    r.push_back(1);
  }
  for (int i = 0; i < m; i++) {
    cin >> k;
    u.push_back(k);
  }
  h = 0;
  for (int i = 0; i < n; i++) {
    q = v[i];
    int j = h;
    int f = 1;
    while ((j < m) && (f == 1)) {
      l = u[j];
      if (l >= q) {
        kol++;
        f = 0;
        j++;
        h++;
      } else {
        j++;
        h++;
      }
    }
  }
  cout << max(0, n - kol);
  return 0;
}
