#include <bits/stdc++.h>
using namespace std;
const int N = 3010;
int n, m;
int a[N], b[N];
bool used[N];
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cin >> n >> m;
  for (int i = 1; i <= n; i++) {
    cin >> a[i];
  }
  for (int i = 1; i <= m; i++) {
    cin >> b[i];
  }
  int res = 0;
  for (int i = 1; i <= n; i++) {
    int p = -1;
    for (int j = 1; j <= m; j++) {
      if (used[j]) {
        continue;
      }
      if (b[j] >= a[i]) {
        p = j;
        break;
      }
    }
    if (p == -1) {
      res++;
    } else {
      used[p] = true;
    }
  }
  cout << res << "\n";
  return 0;
}
