#include <bits/stdc++.h>
using namespace std;
const long long ubound = 2001;
int main() {
  int n, p;
  cin >> n >> p;
  string st;
  cin >> st;
  st = "..." + st + "...";
  char m = 'a' + p;
  int i = n + 2;
  for (; i >= 3; i--) {
    char c = st[i];
    for (char j = c + 1; j < m; j++) {
      if (st[i - 2] == j || st[i - 1] == j)
        continue;
      else {
        st[i] = j;
        goto break2;
      }
    }
  }
  cout << "NO";
  return 0;
break2:;
  for (i = i + 1; i < n + 3; i++) {
    char c = 'a';
    for (char j = c; j < m; j++) {
      if (st[i - 2] == j || st[i - 1] == j)
        continue;
      else {
        st[i] = j;
        break;
      }
    }
  }
  for (int i = 3; i < n + 3; i++) cout << st[i];
}
