#include <bits/stdc++.h>
using namespace std;
const int MAX = 6e3;
int dp[MAX + 10];
int a, b;
string s;
int n;
int nex[MAX + 10];
int che[MAX + 10][MAX + 10];
int check(int ed) {
  int l = ed;
  int ret = 0;
  int j = 0;
  nex[0 + l] = nex[1 + l] = 0;
  for (int i = 1; i + l < n; i++) {
    int j = nex[i];
    while (j && s[i + l] != s[j + l]) j = nex[j];
    nex[i + 1] = s[i + l] == s[j + l] ? j + 1 : 0;
  }
  for (int i = 0; i < ed; i++) {
    while (j && s[i] != s[j + l]) j = nex[j];
    if (s[i] == s[l + j]) j++;
    ret = max(ret, j);
    if (l + j == n) return ret;
  }
  return ret;
}
int main(void) {
  cin >> n >> a >> b;
  cin >> s;
  memset(che, 0, sizeof(che));
  for (int i = 1; i <= n; i++) {
    int mid = check(i);
    int k = i + 1;
    while (k <= i + mid) che[i][k++] = 1;
    while (k <= n) che[i][k++] = 0;
  }
  dp[0] = 0;
  for (int i = 1; i <= n; i++) dp[i] = MAX * MAX;
  for (int i = 1; i <= n; i++) {
    dp[i] = dp[i - 1] + a;
    for (int j = i - 1; j; j--) {
      if (che[j][i]) dp[i] = min(dp[i], dp[j] + b);
    }
  }
  printf("%d", dp[n]);
}
