#include <bits/stdc++.h>
const int MOD = 1e9 + 7;
const long long int INF = 2e18;
const int mxn = 2e9 + 9;
const int mxd = 2e5 + 5;
using namespace std;
void SoLuTioN() {
  int n, a, b;
  cin >> n >> a >> b;
  vector<int> v(n);
  for (int i = 0; i < n; i++) {
    cin >> v[i];
    if (v[i] == 1)
      a--;
    else {
      if (b > 0)
        b--;
      else
        a--;
    }
  }
  if (a < 0)
    cout << a * (-1) << '\n';
  else
    cout << "0" << '\n';
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int T;
  T = 1;
  while (T--) {
    SoLuTioN();
  }
  return 0;
}
