#include <bits/stdc++.h>
using namespace std;
int n, a, b;
const int maxn = 5005;
char s[maxn];
long long dp[maxn] = {0};
unsigned long long f[maxn], p[maxn];
const long long inf = 0x3f3f3f3f3f3f3f3f;
int z[maxn];
void init(char *S) {
  int n = strlen(S);
  z[0] = n;
  int j = 1, k;
  for (int i = 1; i < n; i = k) {
    if (j < i) j = i;
    while (j < n && S[j] == S[j - i]) j++;
    z[i] = j - i;
    k = i + 1;
    while (k + z[k - i] < j) z[k] = z[k - i], k++;
  }
}
char t[maxn];
int main() {
  scanf("%d%d%d", &n, &a, &b);
  scanf("%s", s);
  for (int i = 0; i <= n; i++) dp[i] = inf;
  dp[0] = 0;
  for (int i = 1; i <= n; i++) {
    dp[i] = min(dp[i], dp[i - 1] + a);
    for (int j = 0; j < i; j++) t[i - j - 1] = s[j];
    t[i] = '\0';
    init(t);
    for (int k = 0; k < i; k++) {
      if (z[k] <= k) {
        dp[i] = min(dp[i], dp[i - z[k]] + b);
      }
    }
  }
  printf("%lld\n", dp[n]);
  return 0;
}
