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