#include <bits/stdc++.h>
using namespace std;
signed main() {
  cin.tie(0);
  cout.tie(0);
  ios_base ::sync_with_stdio(0);
  long long n, a, b;
  cin >> n >> a >> b;
  string s;
  cin >> s;
  long long z[5005] = {};
  long long max_match[5005] = {};
  for (long long start = 0; start < n; start++) {
    for (long long i = start + 1, l = -1, r = -1; i < s.size(); i++) {
      z[i] = 0;
      if (i <= r) {
        z[i] = min(z[i - l + start], r - i + 1);
      }
      while (i + z[i] < s.size() && s[i + z[i]] == s[start + z[i]]) {
        z[i]++;
      }
      if (i + z[i] - 1 > r) {
        l = i;
        r = i + z[i] - 1;
      }
      max_match[i] = max(max_match[i], min(z[i], i - start));
    }
  }
  long long dp[n];
  for (long long i = 0; i < n; i++) {
    dp[i] = 1e9;
  }
  dp[0] = a;
  for (long long i = 0; i < n; i++) {
    if (i) {
      dp[i] = min(dp[i], dp[i - 1] + a);
    }
    if (i == n - 1) continue;
    for (long long len = 1; len <= max_match[i + 1]; len++) {
      dp[i + len] = min(dp[i + len], dp[i] + b);
    }
  }
  cout << dp[n - 1];
  return 0;
}
