#include <bits/stdc++.h>
using namespace std;
const long long NMAX = 1000000, INF = 1000000000000000000,
                LITTLE_INF = 2000000000;
int zf(string second, int last) {
  int n = second.size();
  vector<int> z(n);
  z[0] = 0;
  int ans = 0;
  for (int i = 1, l = 0, r = 0; i < n; ++i) {
    if (i <= r) z[i] = min(r - i + 1, z[i - l]);
    while (i + z[i] < n && second[z[i]] == second[i + z[i]]) ++z[i];
    if (i + z[i] - 1 > r) {
      r = i + z[i] - 1;
      l = i;
    }
    if (i >= last) ans = max(ans, z[i]);
  }
  return ans;
}
vector<int> v[5005];
int main() {
  {
    ios_base::sync_with_stdio(false);
    cin.tie(0);
    cout.tie(0);
  }
  string x, y;
  int n, a, b;
  cin >> n >> a >> b >> x;
  y.push_back(x[0]);
  x.erase(x.begin());
  for (int i = 1; i < n; ++i) {
    int c = zf(x + "#" + y, x.size());
    for (int j = 1; j <= c; ++j) v[i + j - 1].push_back(j);
    y.push_back(x[0]);
    x.erase(x.begin());
  }
  vector<int> dp(n);
  dp[0] = a;
  for (int i = 1; i < n; ++i) {
    dp[i] = dp[i - 1] + a;
    for (int c : v[i]) {
      dp[i] = min(dp[i], dp[i - c] + b);
    }
  }
  cout << dp[n - 1];
}
