#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, k;
  int x, y, a, b;
  x = y = 0;
  cin >> n >> m >> k;
  int t;
  for (int i = 1; i <= n; i++) {
    cin >> t;
    if (t == 1)
      x++;
    else
      y++;
  }
  if (x > m) {
    a = x - m;
    if (k >= y)
      b = 0;
    else {
      b = abs(y - k);
    }
  } else {
    a = 0;
    if (k + m - x >= y)
      b = 0;
    else
      b = abs(k + m - x - y);
  }
  cout << a + b << endl;
  return 0;
}
