#include <bits/stdc++.h>
using namespace std;
char s[1005], aux[1005];
int sz;
bool ok(int ind, char l) {
  if (ind - 2 >= 0 && l == aux[ind - 2]) return false;
  if (ind - 1 >= 0 && l == aux[ind - 1]) return false;
  return true;
}
int main() {
  int n;
  scanf("%d %d %s", &sz, &n, s);
  for (int i = strlen(s) - 1; i >= 0; i--) {
    for (int j = 0; s[j]; j++) aux[j] = s[j];
    bool deuruim = false;
    for (int j = i; s[j]; j++) {
      char st;
      if (i == j)
        st = s[j] + 1;
      else
        st = 'a';
      bool good = false;
      for (char l = st; l < 'a' + n; l++) {
        if (ok(j, l)) {
          good = true;
          aux[j] = l;
          break;
        }
      }
      if (!good) {
        deuruim = true;
        break;
      }
    }
    if (!deuruim) {
      printf("%s\n", aux);
      return 0;
    }
  }
  printf("NO\n");
  return 0;
}
