#include <bits/stdc++.h>
using namespace std;
long long n, a, b, zr[5005];
string str;
long long Z(string, long long[]), dp[5005];
int main() {
  cin >> n >> a >> b;
  cin >> str;
  dp[0] = a;
  for (int i = 1; i < n; i++) {
    string ss = str.substr(0, i + 1);
    reverse(ss.begin(), ss.end());
    long long x = Z(ss, zr);
    dp[i] = dp[i - 1] + a;
    dp[i] = min(dp[i], dp[max(i / 2ll, i - x)] + b);
  }
  cout << dp[n - 1];
}
long long Z(string str, long long zr[]) {
  long long l = 0, r = 0, size_ = str.length(), max_ = 0;
  for (int i = 1; i < size_; i++) {
    if (i <= r) {
      long long k = i - l;
      if (zr[k] < (r - i)) {
        zr[i] = zr[k];
      } else {
        l = i;
        while (r < size_ && str[r] == str[r - i]) r++;
        zr[i] = r - l;
      }
    } else {
      l = r = i;
      while (r < size_ && str[r - l] == str[r]) {
        r++;
      }
      zr[i] = (r - l);
    }
    max_ = max(max_, min(zr[i], (long long)i));
  }
  return max_;
}
