#include <bits/stdc++.h>
using namespace std;
int n, p;
string s, res;
bool vis[1000][2][28][28];
bool calc(int i, bool l, int a, int b) {
  if (a == b) return false;
  if (i == s.size()) return l;
  if (vis[i][l][a][b]) return false;
  vis[i][l][a][b] = true;
  if (!l) {
    res[i] = s[i];
    if (calc(i + 1, l, b, s[i] - 'a')) return true;
    for (int j = l ? 0 : s[i] - 'a'; j < p; ++j) {
      res[i] = j + 'a';
      if (j != a && calc(i + 1, l || res[i] != s[i], b, j)) return true;
    }
  } else {
    for (int j = l ? 0 : s[i] - 'a'; j < p; ++j) {
      res[i] = j + 'a';
      if (j != a && calc(i + 1, l || res[i] != s[i], b, j)) return true;
    }
    res[i] = s[i];
    if (calc(i + 1, l, b, s[i] - 'a')) return true;
  }
  res[i] = s[i];
  return false;
}
int main() {
  cin >> n >> p >> s;
  res = s;
  if (!calc(0, false, 26, 27)) res = "NO";
  cout << res << endl;
  return 0;
}
