#include <bits/stdc++.h>
using namespace std;
void func(void) {
  freopen("in.txt", "r", stdin);
  freopen("out.txt", "w", stdout);
}
int cnt[3];
int main() {
  int n, m, k;
  cin >> n >> m >> k;
  int arr[n];
  int a;
  for (int i = 0; i < n; i++) {
    cin >> a;
    cnt[a]++;
  }
  int ans = 0;
  if (cnt[1] > m) {
    ans += (cnt[1] - m);
    m = 0;
  } else
    m -= cnt[1];
  if (cnt[2] > (m + k)) ans += cnt[2] - (m + k);
  cout << ans << endl;
  return 0;
}
