#include <bits/stdc++.h>
using namespace std;
long long c[3005];
int main() {
  long long n, m, d, k = 0, j;
  cin >> n >> m;
  vector<long long> v;
  vector<long long>::iterator it;
  long long a[n], b, i;
  for (i = 0; i < n; i++) {
    cin >> a[i];
  }
  for (i = 0; i < m; i++) {
    cin >> b;
    v.push_back(b);
  }
  sort(v.begin(), v.end());
  for (i = 0; i < n; i++) {
    it = lower_bound(v.begin(), v.end(), a[i]);
    d = it - v.begin();
    long long p = 0;
    for (j = d; j < m; j++) {
      if (c[j] == 0) {
        c[j] = 1;
        p = 1;
        break;
      }
    }
    if (p == 0) k++;
  }
  cout << k << endl;
}
