#include <bits/stdc++.h>
using namespace std;
const char InFile[] = "cfA.in";
const char OutFile[] = "cfA.out";
int N, M, K, sol, ai;
int main() {
  scanf("%d %d %d", &N, &M, &K);
  for (register int i = 1; i <= N; ++i) {
    scanf("%d", &ai);
    if (ai == 1) {
      if (M == 0) {
        ++sol;
      } else {
        --M;
      }
    } else {
      if (K == 0 && M == 0) {
        ++sol;
      } else if (K == 0) {
        --M;
      } else {
        --K;
      }
    }
  }
  printf("%d", sol);
  return 0;
}
