#include <bits/stdc++.h>
using namespace std;
const long long inf = 1e9;
const long long inf64 = 1e18;
const long long MOD = inf + 7;
long long n, p;
string s;
string ans;
long long update_indx = -1;
void solve(long long id) {
  if (id < 0) {
    cout << "NO";
    exit(0);
  }
  set<long long> not_ava;
  if (id >= 1) not_ava.insert(s[id - 1]);
  if (id >= 2) not_ava.insert(s[id - 2]);
  for (char a = 'a'; a <= 'a' + p - 1; a++) {
    if (a > s[id] && not_ava.find(a) == not_ava.end()) {
      ans[id] = a;
      update_indx = id;
      return;
    }
  }
  solve(id - 1);
}
int32_t main() {
  ios::sync_with_stdio(false), cin.tie(nullptr);
  ;
  cin >> n >> p >> s;
  ans = s;
  solve(n - 1);
  for (long long i = update_indx + 1; i < n; i++) {
    for (char c = 'a'; c <= 'a' + p - 1; c++) {
      long long ok = 1;
      if (i >= 1 && ans[i - 1] == c) ok = 0;
      if (i >= 2 && ans[i - 2] == c) ok = 0;
      if (ok) {
        ans[i] = c;
        break;
      }
    }
  }
  cout << ans;
}
