#include <bits/stdc++.h>
#pragma warning(disable : 4996)
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  int n, m;
  cin >> n >> m;
  int round[3005];
  int problems[3005];
  for (int i = 0; i < n; i++) {
    cin >> round[i];
  }
  for (int i = 0; i < m; i++) {
    cin >> problems[i];
  }
  int j = 0;
  int i = 0;
  int res = n;
  for (i = 0; i < n; i++) {
    for (; j < m; j++) {
      if (problems[j] >= round[i]) {
        j++;
        res--;
        break;
      }
    }
  }
  cout << res;
  return 0;
}
