#include <bits/stdc++.h>
using namespace std;
const int maxn = 5002;
const int inf = 1e9;
char str[maxn];
int n, a, b;
int dp[maxn];
int fail[maxn];
void kmp(char *str, int n, int *fail);
int match(char *str, char *s, int n, int m, int *fail);
int main() {
  scanf("%d%d%d", &n, &a, &b);
  scanf("%s", str + 1);
  for (int i = 1; i <= n; i++) {
    dp[i] = inf;
  }
  for (int i = 0; i < n; i++) {
    kmp(str + i, n - i, fail);
    int cur = match(str, str + i, i, n - i, fail);
    for (int j = i + 1; j <= i + cur; j++) {
      dp[j] = min(dp[j], dp[i] + b);
    }
    dp[i + 1] = min(dp[i + 1], dp[i] + a);
  }
  printf("%d", dp[n]);
  return 0;
}
void kmp(char *str, int n, int *fail) {
  fail[1] = 0;
  for (int i = 2; i <= n; i++) {
    int cur = fail[i - 1];
    while (cur && str[cur + 1] != str[i]) cur = fail[cur];
    if (str[cur + 1] == str[i]) cur++;
    fail[i] = cur;
  }
}
int match(char *str, char *s, int n, int m, int *fail) {
  int ans = 0;
  int cur = 0;
  for (int i = 1; i <= n; i++) {
    while (cur && s[cur + 1] != str[i]) cur = fail[cur];
    if (cur < m && s[cur + 1] == str[i]) cur++;
    ans = max(ans, cur);
  }
  return ans;
}
