#include <bits/stdc++.h>
using namespace std;
void no() {
  cout << -1;
  exit(0);
}
bool is_prime(int64_t a) {
  for (int64_t i = 2; i * i < a; ++i) {
    if (a % i == 0) return false;
  }
  return true;
}
struct Hsh {
  vector<int64_t> p, h;
  int64_t MOD, P = 37;
  int64_t md(int64_t a) { return (a + MOD) % MOD; }
  Hsh() {}
  Hsh(string &str, int64_t M) {
    MOD = M;
    int64_t n = str.size();
    p.resize(n + 1);
    h.resize(n + 1);
    p[0] = 1;
    for (int64_t i = 0; i < n; ++i) {
      h[i + 1] = md(h[i] * P + str[i]);
      p[i + 1] = md(p[i] * P);
    }
  }
  int64_t hsh(int64_t l, int64_t r) {
    return md(h[r + 1] - (h[l] * p[r - l + 1]) % MOD);
  }
};
const int64_t MD = 1e9 + 207;
Hsh hsh;
string str;
bool check(int64_t lst, int64_t len, int64_t hs) {
  for (int64_t i = 0; i < lst - len + 1; ++i) {
    int64_t h = hsh.hsh(i, i + len - 1);
    if (h == hs) return true;
  }
  return false;
}
void rn(int64_t &a, int64_t b) { a = min(a, b); }
int32_t main() {
  int64_t n, A, B;
  cin >> n >> A >> B;
  cin >> str;
  hsh = Hsh(str, MD);
  vector<int64_t> prec(n);
  for (int64_t i = 0; i < n; ++i) {
    int64_t l = i, r = n;
    while (l < r) {
      int64_t mid = (l + r) / 2;
      int64_t hs = hsh.hsh(i, mid);
      if (check(i, mid - i + 1, hs))
        l = mid + 1;
      else
        r = mid;
    }
    prec[i] = l - i;
  }
  vector<int64_t> dp(n, LLONG_MAX);
  dp[0] = A;
  for (int64_t i = 0; i < n - 1; ++i) {
    rn(dp[i + 1], dp[i] + A);
    for (int64_t j = i + 1; j <= i + prec[i + 1]; ++j) {
      rn(dp[j], dp[i] + B);
    }
  }
  cout << dp[n - 1];
}
