#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  long long n, m, k;
  cin >> n >> m >> k;
  int arr[n];
  int counter = 0;
  for (int i = 0; i < n; cin >> arr[i++])
    ;
  for (int i = 0; i < n; i++) {
    if (arr[i] == 1) {
      if (m == 0)
        counter++;
      else if (m > 0)
        m--;
    } else if (arr[i] == 2) {
      if (m == 0 && k == 0)
        counter++;
      else if (k > 0)
        k--;
      else
        m--;
    }
  }
  cout << counter << endl;
  return 0;
}
