#include <bits/stdc++.h>
using namespace std;
string s;
int a, b;
int z[5010][5010];
void solve(string s, int t) {
  int L = 0, R = 0;
  int n = s.size();
  for (int i = 0; i < n / 2; ++i) swap(s[i], s[n - 1 - i]);
  for (int i = 1; i <= n - 1; ++i) {
    if (i > R) {
      L = R = i;
      while (R < n && s[R - L] == s[R]) R++;
      z[t][i + t] = R - L;
      R--;
    } else {
      int k = i - L;
      if (z[t][k + t] < R - i + 1)
        z[t][i + t] = z[t][k + t];
      else {
        L = i;
        while (R < n && s[R - L] == s[R]) R++;
        z[t][i + t] = R - L;
        R--;
      }
    }
  }
}
long long int dp[5010];
void init() {
  for (int i = 0; i < 5010; ++i) dp[i] = INT_MAX;
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  cin >> a >> b >> s;
  string k = s;
  for (int i = 0; i < n / 2; ++i) swap(k[i], k[n - 1 - i]);
  for (int i = 0; i < n; ++i) {
    solve(k, i);
    k.pop_back();
  }
  int ans = a;
  int i = 1;
  init();
  dp[0] = a;
  for (int i = 0; i < n; ++i) {
    int ss = 0;
    dp[i] = min(dp[i], dp[i - 1] + a);
    for (int j = 0; j < i; ++j) {
      int l = min(z[j][i], i - j);
      if (l) dp[i + l - 1] = min(dp[i + l - 1], b + dp[i - 1]);
    }
  }
  cout << dp[n - 1];
  return 0;
}
