#include <bits/stdc++.h>
using namespace std;
int main() {
  int t, i, j, n, m, ans, sum, p, len, z, y, x, f, idx;
  string s;
  char ch;
  cin >> n >> p;
  cin >> s;
  len = s.length();
  {
    f = 0;
    for (i = len - 1; i >= 0; i--) {
      for (j = 1; j <= p; j++) {
        z = s[i] - 'a' + j;
        z++;
        y = -1;
        x = -1;
        if (z <= p) {
          if (i > 0) y = s[i - 1] - 'a' + 1;
          if (i > 1) x = s[i - 2] - 'a' + 1;
          if (z != x && z != y) {
            s[i] = (char)z + 'a' - 1;
            idx = i;
            f = 1;
            break;
          }
        } else
          break;
      }
      if (f) break;
    }
    if (!f) {
      cout << "NO";
      return 0;
    }
    for (i = idx + 1; i < len; i++) {
      for (j = 1; j <= p; j++) {
        ch = (char)'a' + j - 1;
        if (ch != s[i - 1] && ch != s[i - 2]) {
          s[i] = ch;
          break;
        }
      }
    }
    cout << s << endl;
  }
  return 0;
}
