#include <bits/stdc++.h>
using namespace std;
struct abc {
  int x, y;
};
int n, k, t, l, r, ans = 0, sum = 0, a, b, x = 0;
bool flag;
char str[200010];
int cnt[200010];
void work() {
  int j = 0;
  flag = 1;
  for (int i = 0; i < n; i++) {
    if (str[i] == '*' && ans) {
      cnt[j++] = ans;
      if (ans % 2 == 0)
        sum += ans;
      else {
        sum += ans - 1;
        x++;
      }
      ans = 0;
    }
    if (str[i] == '.') ans++;
  }
  cnt[j++] = ans;
  if (ans % 2 == 0)
    sum += ans;
  else {
    sum += ans - 1;
    x++;
  }
  ans = 0;
  if (sum / 2 <= min(a, b)) {
    cout << min(sum + x, a + b) << endl;
  } else {
    cout << min(sum / 2 + min(a, b) + x, a + b) << endl;
  }
}
int main() {
  cin >> n >> a >> b;
  cin >> str;
  work();
}
