#include <bits/stdc++.h>
using namespace std;
const int N = 5 * 1000 + 3;
const int MOD = 1000003373, BASE = 29, INV = 517243124;
int n, a, b;
string st;
int dp[N], lim[N];
int inv[N], mash[N];
void input() {
  cin.tie(0);
  cin >> n >> a >> b;
  cin >> st;
}
void prePare() {
  int pw = BASE;
  mash[0] = (st[0] - 'a' + 1);
  for (int i = 1; i < n; i++) {
    mash[i] = ((1ll * (st[i] - 'a' + 1) * pw) + mash[i - 1]) % MOD;
    pw = (1ll * pw * BASE) % MOD;
  }
  inv[0] = 1;
  for (int i = 1; i < n; i++) inv[i] = (1ll * inv[i - 1] * INV) % MOD;
}
int subStr(int l, int r) {
  if (l == 0) return mash[r - 1];
  return (((0ll + mash[r - 1] - mash[l - 1] + MOD) % MOD) * inv[l]) % MOD;
}
void solve() {
  prePare();
  for (int i = 0; i < n; i++) {
    int L = 0, R = i + 1, mid;
    while (R - L > 1) {
      mid = (L + R) >> 1;
      bool flag = false;
      for (int j = 0; j < 2 * mid - i; j++)
        if (subStr(j, j + i + 1 - mid) == subStr(mid, i + 1)) {
          R = mid;
          flag = true;
          break;
        }
      if (!flag) L = mid;
    }
    lim[i] = R;
  }
  dp[0] = a;
  for (int i = 1; i < n; i++) {
    dp[i] = a + dp[i - 1];
    for (int j = i; j >= lim[i]; j--) dp[i] = min(dp[i], dp[j - 1] + b);
  }
}
int main() {
  ios::sync_with_stdio(false);
  input();
  solve();
  cout << dp[n - 1] << endl;
  return 0;
}
