#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, k;
  cin >> n >> m >> k;
  int x;
  int res = 0;
  int first = 0, second = 0;
  for (int i = 0; i < n; i++) {
    cin >> x;
    if (x == 1)
      first++;
    else if (x == 2)
      second++;
  }
  if (first <= m)
    m -= first;
  else {
    res += (first - m);
    m = 0;
  }
  if (m + k < second) res += (second - m - k);
  cout << res << endl;
}
