import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.InputMismatchException;
import java.io.BufferedWriter;
import java.io.PrintWriter;
import java.io.Writer;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.IOException;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author Alex
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        OutputWriter out = new OutputWriter(outputStream);
        TaskA solver = new TaskA();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskA {
        String BAD = "NO";
        OutputWriter out;
        int n;
        int p;
        char[] input;
        int[] a;

        boolean next() {
            for(int i = a.length - 1; i >= 0; i--) {
                if(a[i] < p - 1) {
                    a[i]++;
                    for(int j = i + 1; j < a.length; j++) {
                        a[j] = 0;
                    }
                    return true;
                }
            }
            return false;
        }

        void print() {
            StringBuilder res = new StringBuilder();
            for(int val : a) res.append((char) (val + 'a'));
            out.printLine(res.toString());
        }

        int backwards(int index) {
            if(index == -1) return -1;
            int res = index;
            while(true) {
                a[index]++;
                if(!bad(index)) break;
                if(a[index] == p) {
                    res = backwards(index - 1);
                }
            }
            return res;
        }

        boolean bad(int index) {
            return (a[index] == p) || (index > 0 && a[index] == a[index - 1]) || (index > 1 && a[index] == a[index - 2]);
        }

        public void solve(int testNumber, InputReader in, OutputWriter out) {
            this.out = out;
            n = in.readInt();
            p = in.readInt();
            input = in.next().toCharArray();
            a = new int[input.length];
            for(int i = 0; i < a.length; i++) a[i] = (input[i] - 'a');
            if(!next()) {
                out.printLine(BAD);
                return;
            }
            for(int i = 1; i < a.length; i++) {
                if(bad(i)) {
                    int modified = backwards(i);
                    if(modified == -1) {
                        out.printLine(BAD);
                        return;
                    }
                    for(int j = modified + 1; j < a.length; j++) {
                        a[j] = 0;
                        while(bad(j)) {
                            a[j]++;
                            if(a[j] == p) {
                                out.printLine(BAD);
                                return;
                            }
                        }
                    }
                    print();
                    return;
                }
            }
            print();
        }

    }

    static class OutputWriter {
        private final PrintWriter writer;

        public OutputWriter(OutputStream outputStream) {
            writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
        }

        public OutputWriter(Writer writer) {
            this.writer = new PrintWriter(writer);
        }

        public void print(Object... objects) {
            for(int i = 0; i < objects.length; i++) {
                if(i != 0)
                    writer.print(' ');
                writer.print(objects[i]);
            }
        }

        public void printLine(Object... objects) {
            print(objects);
            writer.println();
        }

        public void close() {
            writer.close();
        }

    }

    static class InputReader {
        private InputStream stream;
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;
        private SpaceCharFilter filter;

        public InputReader(InputStream stream) {
            this.stream = stream;
        }

        public int read() {
            if(numChars == -1)
                throw new InputMismatchException();
            if(curChar >= numChars) {
                curChar = 0;
                try {
                    numChars = stream.read(buf);
                } catch(IOException e) {
                    throw new InputMismatchException();
                }
                if(numChars <= 0)
                    return -1;
            }
            return buf[curChar++];
        }

        public int readInt() {
            int c = read();
            while(isSpaceChar(c))
                c = read();
            int sgn = 1;
            if(c == '-') {
                sgn = -1;
                c = read();
            }
            int res = 0;
            do {
                if(c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            } while(!isSpaceChar(c));
            return res * sgn;
        }

        public String readString() {
            int c = read();
            while(isSpaceChar(c))
                c = read();
            StringBuilder res = new StringBuilder();
            do {
                if(Character.isValidCodePoint(c))
                    res.appendCodePoint(c);
                c = read();
            } while(!isSpaceChar(c));
            return res.toString();
        }

        public boolean isSpaceChar(int c) {
            if(filter != null)
                return filter.isSpaceChar(c);
            return isWhitespace(c);
        }

        public static boolean isWhitespace(int c) {
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        public String next() {
            return readString();
        }

        public interface SpaceCharFilter {
            public boolean isSpaceChar(int ch);

        }

    }
}


import java.io.InputStream;
import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.util.InputMismatchException;
import java.io.BufferedWriter;
import java.io.PrintWriter;
import java.io.Writer;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.IOException;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author Alex
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        OutputWriter out = new OutputWriter(outputStream);
        TaskA solver = new TaskA();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskA {
        String BAD = "NO";
        OutputWriter out;
        int n;
        int p;
        char[] input;
        int[] a;

        boolean next() {
            for(int i = a.length - 1; i >= 0; i--) {
                if(a[i] < p - 1) {
                    a[i]++;
                    for(int j = i + 1; j < a.length; j++) {
                        a[j] = 0;
                    }
                    return true;
                }
            }
            return false;
        }

        void print() {
            StringBuilder res = new StringBuilder();
            for(int val : a) res.append((char) (val + 'a'));
            out.printLine(res.toString());
        }

        int backwards(int index) {
            if(index == -1) return -1;
            int res = index;
            while(true) {
                a[index]++;
                if(!bad(index)) break;
                if(a[index] == p) {
                    res = backwards(index - 1);
                }
            }
            return res;
        }

        boolean bad(int index) {
            return (a[index] == p) || (index > 0 && a[index] == a[index - 1]) || (index > 1 && a[index] == a[index - 2]);
        }

        public void solve(int testNumber, InputReader in, OutputWriter out) {
            this.out = out;
            n = in.readInt();
            p = in.readInt();
            input = in.next().toCharArray();
            a = new int[input.length];
            for(int i = 0; i < a.length; i++) a[i] = (input[i] - 'a');
//        slowsolve();
            if(!next()) {
                out.printLine(BAD);
                return;
            }
            for(int i = 1; i < a.length; i++) {
                if(bad(i)) {
                    //want to increment right here
                    int modified = backwards(i);
                    if(modified == -1) {
                        out.printLine(BAD);
                        return;
                    }
                    for(int j = modified + 1; j < a.length; j++) {
                        a[j] = 0;
                        while(bad(j)) {
                            a[j]++;
                            if(a[j] == p) {
                                out.printLine(BAD);
                                return;
                            }
                        }
                    }
//                a[i]++;
//                if (a[i] == p || (a[i] == a[i - 1] || (i > 1 && a[i] == a[i - 2]))){
//                    backwards(i - 1);
//                }
                    //afterwards we just need to get the pattern together
//                for(int j = i + 1; j < a.length; j++) {
//                    int want = 0;
//                    while((j > 0 && a[j - 1] == want) || (j > 1 && a[j - 2] == want)) want++;
//                    a[j] = want;
//                }
                    print();
                    return;
                }
            }
            print();
//        if (n <= 3) {
//            slowsolve();
//        } else {
//            if (p == 2) {
//                out.printLine("NO");
//            } else {
//
//            }
//        }
        }

    }

    static class OutputWriter {
        private final PrintWriter writer;

        public OutputWriter(OutputStream outputStream) {
            writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
        }

        public OutputWriter(Writer writer) {
            this.writer = new PrintWriter(writer);
        }

        public void print(Object... objects) {
            for(int i = 0; i < objects.length; i++) {
                if(i != 0)
                    writer.print(' ');
                writer.print(objects[i]);
            }
        }

        public void printLine(Object... objects) {
            print(objects);
            writer.println();
        }

        public void close() {
            writer.close();
        }

    }

    static class InputReader {
        private InputStream stream;
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;
        private SpaceCharFilter filter;

        public InputReader(InputStream stream) {
            this.stream = stream;
        }

        public int read() {
            if(numChars == -1)
                throw new InputMismatchException();
            if(curChar >= numChars) {
                curChar = 0;
                try {
                    numChars = stream.read(buf);
                } catch(IOException e) {
                    throw new InputMismatchException();
                }
                if(numChars <= 0)
                    return -1;
            }
            return buf[curChar++];
        }

        public int readInt() {
            int c = read();
            while(isSpaceChar(c))
                c = read();
            int sgn = 1;
            if(c == '-') {
                sgn = -1;
                c = read();
            }
            int res = 0;
            do {
                if(c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            } while(!isSpaceChar(c));
            return res * sgn;
        }

        public String readString() {
            int c = read();
            while(isSpaceChar(c))
                c = read();
            StringBuilder res = new StringBuilder();
            do {
                if(Character.isValidCodePoint(c))
                    res.appendCodePoint(c);
                c = read();
            } while(!isSpaceChar(c));
            return res.toString();
        }

        public boolean isSpaceChar(int c) {
            if(filter != null)
                return filter.isSpaceChar(c);
            return isWhitespace(c);
        }

        public static boolean isWhitespace(int c) {
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        public String next() {
            return readString();
        }

        public interface SpaceCharFilter {
            public boolean isSpaceChar(int ch);

        }

    }
}


import java.io.IOException;
import java.io.OutputStreamWriter;
import java.io.BufferedWriter;
import java.util.InputMismatchException;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.NoSuchElementException;
import java.io.Writer;
import java.math.BigInteger;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 * @author Alex
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(inputStream);
		OutputWriter out = new OutputWriter(outputStream);
		TaskA solver = new TaskA();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskA {
	char[] inc(char[] cur, int a, int p){
		if (a < 0) return null;
		cur[a]++;
		if (cur[a] > 'a'-1+p){
			if (inc(cur, a-1, p)!=null){
				cur[a] = 'a' - 1;
				return inc(cur, a, p);
			}
			else return null;
		}
		else if ((a >= 1 && cur[a] == cur[a-1]) || (a>=2 && cur[a] == cur[a-2])) return inc(cur, a, p);
		return cur;
	}

    public void solve(int testNumber, InputReader in, OutputWriter out) {
		int n = in.readInt(), p = in.readInt();
		char[] ca = in.next().toCharArray();
		char[] res = inc(ca, n-1, p);
		if (res == null) out.print("NO");
		else for(char c: res) out.print(c);
	}
}

class InputReader {
	private InputStream stream;
	private byte[] buf = new byte[1024];
	private int curChar;
	private int numChars;
	private SpaceCharFilter filter;

	public InputReader(InputStream stream) {
		this.stream = stream;
	}

	public int read() {
		if (numChars == -1)
			throw new InputMismatchException();
		if (curChar >= numChars) {
			curChar = 0;
			try {
				numChars = stream.read(buf);
			} catch (IOException e) {
				throw new InputMismatchException();
			}
			if (numChars <= 0)
				return -1;
		}
		return buf[curChar++];
	}
	public int readInt() {
		int c = read();
		while (isSpaceChar(c))
			c = read();
		int sgn = 1;
		if (c == '-') {
			sgn = -1;
			c = read();
		}
		int res = 0;
		do {
			if (c < '0' || c > '9')
				throw new InputMismatchException();
			res *= 10;
			res += c - '0';
			c = read();
		} while (!isSpaceChar(c));
		return res * sgn;
	}
	public String readString() {
		int c = read();
		while (isSpaceChar(c))
			c = read();
		StringBuilder res = new StringBuilder();
		do {
			if (Character.isValidCodePoint(c))
				res.appendCodePoint(c);
			c = read();
		} while (!isSpaceChar(c));
		return res.toString();
	}

	public boolean isSpaceChar(int c) {
		if (filter != null)
			return filter.isSpaceChar(c);
		return isWhitespace(c);
	}

	public static boolean isWhitespace(int c) {
		return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
	}
	public String next() {
		return readString();
	}
	public interface SpaceCharFilter {
		public boolean isSpaceChar(int ch);
	}
}

class OutputWriter {
	private final PrintWriter writer;

	public OutputWriter(OutputStream outputStream) {
		writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
	}
	public void print(Object...objects) {
		for (int i = 0; i < objects.length; i++) {
			if (i != 0)
				writer.print(' ');
			writer.print(objects[i]);
		}
	}
	public void print(char i) {
		writer.print(i);
	}
	public void close() {
		writer.close();
	}
}


import java.util.Scanner;

public class NoToPalindromes {
	public static void main(String[] args) {
		Scanner scan=new Scanner(System.in);
		n=scan.nextInt();
		k=scan.nextInt();
		s=scan.next();

		dp=new Boolean[2][27][27][n];
		res=new char[n];

		boolean x=go(0,26,26,0);
		if(x) System.out.println(new String(res));
		else System.out.println("NO");
	}
	static char[] res;
	static int n,k;
	static Boolean[][][][] dp;
	static String s;

	//...prev1...prev2...charAt(ind)

	public static boolean go(int bigger, int prev1, int prev2, int ind) {
		if(ind==n) {
			//if you reach the end it needs to be lexicographically later
			return bigger==1?true:false;
		}
		if(dp[bigger][prev1][prev2][ind]!=null) return dp[bigger][prev1][prev2][ind];

		int start=bigger==1?0:s.charAt(ind)-'a';

		for(int i=start;i<k;i++) {

			//check if it makes a palindrome by checking the previous 2 characters
			if(i==prev1||i==prev2) continue;

			//is it lexicographically later
			boolean next=bigger==1;
			if('a'+i>s.charAt(ind)) next=true;
			//omg
			boolean solve=go(next?1:0,prev2,i,ind+1);

			if(solve) {
				res[ind]=(char)(i+'a');
				return dp[bigger][prev1][prev2][ind]=true;
			}
		}
		return dp[bigger][prev1][prev2][ind]=false;
	}
}


import java.util.Scanner;

public class NoToPalindromes {
	public static void main(String[] args) {
		Scanner scan=new Scanner(System.in);
		n=scan.nextInt();
		k=scan.nextInt();
		s=scan.next();

		dp=new Boolean[2][27][27][n];
		res=new char[n];

		boolean x=go(0,26,26,0);
		if(x) System.out.println(new String(res));
		else System.out.println("NO");
	}
	static char[] res;
	static int n,k;
	static Boolean[][][][] dp;
	static String s;

	//...prev1...prev2...charAt(ind)

	public static boolean go(int bigger, int prev1, int prev2, int ind) {
		if(ind==n) {
			//if you reach the end it needs to be lexicographically later
			return bigger==1?true:false;
		}
		if(dp[bigger][prev1][prev2][ind]!=null) return dp[bigger][prev1][prev2][ind];

		int start=bigger==1?0:s.charAt(ind)-'a';

		for(int i=start;i<k;i++) {

			//check if it makes a palindrome by checking the previous 2 characters
			if(i==prev1||i==prev2) continue;

			//is it lexicographically later
			boolean next=bigger==1;
			if('a'+i>s.charAt(ind)) next=true;
			boolean solve=go(next?1:0,prev2,s.charAt(ind)-'a',ind+1);

			if(solve) {
				res[ind]=(char)(i+'a');
				return dp[bigger][prev1][prev2][ind]=true;
			}
		}
		return dp[bigger][prev1][prev2][ind]=false;
	}
}


import java.io.*;
import java.math.BigInteger;
import java.util.*;

public class Main {
    static boolean isMultiTest = false;

    public static void main(String[] args) {
        OutputStream outputStream = System.out;
        InputStream inputStream = System.in;
        InputFast in = new InputFast();
        PrintWriter out = new PrintWriter(outputStream);
        Task solver = new Task();
        if (isMultiTest) {
            int testNumber = in.nextInt();
            for (int i = 1; i <= testNumber; i++) {
                solver.solve(i, in, out);
            }
        } else {
            solver.solve(1, in, out);
        }
        out.close();
    }
}

class Task {
    final static int MOD = 1000 * 1000 * 1000 + 7;

    public void solve(int testNumber, InputFast in, PrintWriter out) {
        int n = in.nextInt();
        int p = in.nextInt();
        char[] s = in.next(n);
        boolean has = false;
        int pos = -1;
        for (int i = n - 1; i >= 0; --i) {
            boolean flag = false;
            for (char c = (char) (s[i] + 1); c < 'a' + p; c++) {
                char l1 = '.';
                char l2 = '.';
                char r1 = '.';
                char r2 = '.';
                if (i - 1 >= 0) {
                    r1 = s[i - 1];
                }
                if (i - 2 >= 0) {
                    r2 = s[i - 2];
                }
                if (ok(c, l1, l2, r1, r2)) {
                    pos = i;
                    flag = true;
                    has = true;
                    s[i] = c;
                    break;
                }
            }
            if (flag)
                break;
        }
        if (!has) {
            out.println("NO");
            return;
        }

        for (int i = pos + 1; i < n; ++i) {
            for (char c = 'a'; c <= 'a' + p; c++) {
                if (i - 2 >= 0 && ok(c, s[i - 1], s[i - 2])) {
                    s[i] = c;
                    break;
                } else if (i - 1 >= 0 && ok(c, s[i - 1])) {
                    s[i] = c;
                    break;
                }
            }
        }
        String ans = new String(s);
        out.println(ans);
    }

    boolean ok(char c, char... o) {
        for (char i : o) {
            if (c == i)
                return false;
        }
        return true;
    }
}

class InputFast {
    static InputStream is = System.in;
    static private byte[] buffer = new byte[1024];
    static private int lenbuf = 0, ptrbuf = 0;

    private int readByte() {
        if (lenbuf == -1)
            throw new InputMismatchException();
        if (ptrbuf >= lenbuf) {
            ptrbuf = 0;
            try {
                lenbuf = is.read(buffer);
            } catch (IOException e) {
                throw new InputMismatchException();
            }
            if (lenbuf <= 0)
                return -1;
        }
        return buffer[ptrbuf++];
    }

    private boolean isSpace(int c) {
        return !(c >= 33 && c <= 126);
    }

    private int read() {
        int b;
        while ((b = readByte()) != -1 && isSpace(b))
            ;
        return b;
    }

    public double nextDouble() {
        return Double.parseDouble(next());
    }

    public char nextChar() {
        return (char) read();
    }

    public String next() {
        int b = read();
        StringBuilder sb = new StringBuilder();
        while (!(isSpace(b))) {
            sb.appendCodePoint(b);
            b = readByte();
        }
        return sb.toString();
    }

    public char[] next(int n) {
        char[] buf = new char[n];
        int b = read(), p = 0;
        while (p < n && !(isSpace(b))) {
            buf[p++] = (char) b;
            b = readByte();
        }
        return n == p ? buf : Arrays.copyOf(buf, p);
    }

    public int nextInt() {
        int num = 0, b;
        boolean minus = false;
        while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
            ;
        if (b == '-') {
            minus = true;
            b = readByte();
        }

        while (true) {
            if (b >= '0' && b <= '9') {
                num = num * 10 + (b - '0');
            } else {
                return minus ? -num : num;
            }
            b = readByte();
        }
    }

    public long nextLong() {
        long num = 0;
        int b;
        boolean minus = false;
        while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
            ;
        if (b == '-') {
            minus = true;
            b = readByte();
        }

        while (true) {
            if (b >= '0' && b <= '9') {
                num = num * 10 + (b - '0');
            } else {
                return minus ? -num : num;
            }
            b = readByte();
        }
    }

}

class Input {
    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public Input(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream), 32768);
        tokenizer = null;
        tokenizer = null;
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return tokenizer.nextToken();
    }

    public String nextLine() {
        String s = "";
        try {
            s = reader.readLine();
        } catch (IOException e) {
            try {
                throw new IOException();
            } catch (IOException e1) {
                e1.printStackTrace();
            }
        }
        return s;
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }

    public long nextLong() {
        return Long.parseLong(next());
    }

    public double nextDouble() {
        return Double.parseDouble(next());
    }
}


import java.io.*;
import java.math.BigInteger;
import java.util.*;

public class Main {
    static boolean isMultiTest = false;

    public static void main(String[] args) {
        OutputStream outputStream = System.out;
        InputStream inputStream = System.in;
        InputFast in = new InputFast();
        PrintWriter out = new PrintWriter(outputStream);
        Task solver = new Task();
        if (isMultiTest) {
            int testNumber = in.nextInt();
            for (int i = 1; i <= testNumber; i++) {
                solver.solve(i, in, out);
            }
        } else {
            solver.solve(1, in, out);
        }
        out.close();
    }
}

class Task {
    final static int MOD = 1000 * 1000 * 1000 + 7;

    public void solve(int testNumber, InputFast in, PrintWriter out) {
        int n = in.nextInt();
        int p = in.nextInt();
        char[] s = in.next(n);
        boolean has = false;
        int pos = -1;
        for (int i = n - 1; i >= 0; --i) {
            boolean flag = false;
            for (char c = (char) (s[i] + 1); c < 'a' + p; c++) {
                char l1 = '.';
                char l2 = '.';
                char r1 = '.';
                char r2 = '.';

                if (i + 1 < n) {
                    r1 = s[i + 1];
                }
                if (i + 2 < n) {
                    r2 = s[i + 2];
                }
                if (i - 1 >= 0) {
                    r1 = s[i - 1];
                }
                if (i - 2 >= 0) {
                    r2 = s[i - 2];
                }
                if (ok(c, l1, l2, r1, r2)) {
                    pos = i;
                    flag = true;
                    has = true;
                    s[i] = c;
                    break;
                }
            }
            if (flag)
                break;
        }
        if (!has) {
            out.println("NO");
            return;
        }

        for (int i = pos + 1; i < n; ++i) {
            for (char c = 'a'; c <= 'a' + p; c++) {
                if (i - 2 >= 0 && ok(c, s[i - 1], s[i - 2])) {
                    s[i] = c;
                    break;
                } else if (i - 1 >= 0 && ok(c, s[i - 1])) {
                    s[i] = c;
                    break;
                }
            }
        }
        String ans = new String(s);
        out.println(ans);
    }

    boolean ok(char c, char... o) {
        for (char i : o) {
            if (c == i)
                return false;
        }
        return true;
    }
}

class InputFast {
    static InputStream is = System.in;
    static private byte[] buffer = new byte[1024];
    static private int lenbuf = 0, ptrbuf = 0;

    private int readByte() {
        if (lenbuf == -1)
            throw new InputMismatchException();
        if (ptrbuf >= lenbuf) {
            ptrbuf = 0;
            try {
                lenbuf = is.read(buffer);
            } catch (IOException e) {
                throw new InputMismatchException();
            }
            if (lenbuf <= 0)
                return -1;
        }
        return buffer[ptrbuf++];
    }

    private boolean isSpace(int c) {
        return !(c >= 33 && c <= 126);
    }

    private int read() {
        int b;
        while ((b = readByte()) != -1 && isSpace(b))
            ;
        return b;
    }

    public double nextDouble() {
        return Double.parseDouble(next());
    }

    public char nextChar() {
        return (char) read();
    }

    public String next() {
        int b = read();
        StringBuilder sb = new StringBuilder();
        while (!(isSpace(b))) {
            sb.appendCodePoint(b);
            b = readByte();
        }
        return sb.toString();
    }

    public char[] next(int n) {
        char[] buf = new char[n];
        int b = read(), p = 0;
        while (p < n && !(isSpace(b))) {
            buf[p++] = (char) b;
            b = readByte();
        }
        return n == p ? buf : Arrays.copyOf(buf, p);
    }

    public int nextInt() {
        int num = 0, b;
        boolean minus = false;
        while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
            ;
        if (b == '-') {
            minus = true;
            b = readByte();
        }

        while (true) {
            if (b >= '0' && b <= '9') {
                num = num * 10 + (b - '0');
            } else {
                return minus ? -num : num;
            }
            b = readByte();
        }
    }

    public long nextLong() {
        long num = 0;
        int b;
        boolean minus = false;
        while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
            ;
        if (b == '-') {
            minus = true;
            b = readByte();
        }

        while (true) {
            if (b >= '0' && b <= '9') {
                num = num * 10 + (b - '0');
            } else {
                return minus ? -num : num;
            }
            b = readByte();
        }
    }

}

class Input {
    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public Input(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream), 32768);
        tokenizer = null;
        tokenizer = null;
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return tokenizer.nextToken();
    }

    public String nextLine() {
        String s = "";
        try {
            s = reader.readLine();
        } catch (IOException e) {
            try {
                throw new IOException();
            } catch (IOException e1) {
                e1.printStackTrace();
            }
        }
        return s;
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }

    public long nextLong() {
        return Long.parseLong(next());
    }

    public double nextDouble() {
        return Double.parseDouble(next());
    }
}


import java.io.*;
import java.math.BigInteger;
import java.util.*;

public class Main {
    static boolean isMultiTest = false;

    public static void main(String[] args) {
        OutputStream outputStream = System.out;
        InputStream inputStream = System.in;
        InputFast in = new InputFast();
        PrintWriter out = new PrintWriter(outputStream);
        Task solver = new Task();
        if (isMultiTest) {
            int testNumber = in.nextInt();
            for (int i = 1; i <= testNumber; i++) {
                solver.solve(i, in, out);
            }
        } else {
            solver.solve(1, in, out);
        }
        out.close();
    }
}

class Task {
    final static int MOD = 1000 * 1000 * 1000 + 7;

    public void solve(int testNumber, InputFast in, PrintWriter out) {
        int n = in.nextInt();
        int p = in.nextInt();
        char[] s = in.next(n);
        boolean has = false;
        int pos = -1;
        for (int i = n - 1; i >= 0; --i) {
            boolean flag = false;
            for (char c = (char) (s[i] + 1); c < 'a' + p; c++) {
                char l1 = '.';
                char l2 = '.';
                char r1 = '.';
                char r2 = '.';
                if (i - 1 >= 0) {
                    r1 = s[i - 1];
                }
                if (i - 2 >= 0) {
                    r2 = s[i - 2];
                }
                if (ok(c, l1, l2, r1, r2)) {
                    pos = i;
                    flag = true;
                    has = true;
                    s[i] = c;
                    break;
                }
            }
            if (flag)
                break;
        }
        if (!has) {
            out.println("NO");
            return;
        }

        for (int i = pos + 1; i < n; ++i) {
            for (char c = 'a'; c <= 'a' + p; c++) {
                if (i - 2 >= 0) {
                    if (ok(c, s[i - 1], s[i - 2])) {
                        s[i] = c;
                        break;
                    }
                } else if (i - 1 >= 0) {
                    if (ok(c, s[i - 1])) {
                        s[i] = c;
                        break;
                    }
                }
            }
        }
        String ans = new String(s);
        out.println(ans);
    }

    boolean ok(char c, char... o) {
        for (char i : o) {
            if (c == i)
                return false;
        }
        return true;
    }
}

class InputFast {
    static InputStream is = System.in;
    static private byte[] buffer = new byte[1024];
    static private int lenbuf = 0, ptrbuf = 0;

    private int readByte() {
        if (lenbuf == -1)
            throw new InputMismatchException();
        if (ptrbuf >= lenbuf) {
            ptrbuf = 0;
            try {
                lenbuf = is.read(buffer);
            } catch (IOException e) {
                throw new InputMismatchException();
            }
            if (lenbuf <= 0)
                return -1;
        }
        return buffer[ptrbuf++];
    }

    private boolean isSpace(int c) {
        return !(c >= 33 && c <= 126);
    }

    private int read() {
        int b;
        while ((b = readByte()) != -1 && isSpace(b))
            ;
        return b;
    }

    public double nextDouble() {
        return Double.parseDouble(next());
    }

    public char nextChar() {
        return (char) read();
    }

    public String next() {
        int b = read();
        StringBuilder sb = new StringBuilder();
        while (!(isSpace(b))) {
            sb.appendCodePoint(b);
            b = readByte();
        }
        return sb.toString();
    }

    public char[] next(int n) {
        char[] buf = new char[n];
        int b = read(), p = 0;
        while (p < n && !(isSpace(b))) {
            buf[p++] = (char) b;
            b = readByte();
        }
        return n == p ? buf : Arrays.copyOf(buf, p);
    }

    public int nextInt() {
        int num = 0, b;
        boolean minus = false;
        while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
            ;
        if (b == '-') {
            minus = true;
            b = readByte();
        }

        while (true) {
            if (b >= '0' && b <= '9') {
                num = num * 10 + (b - '0');
            } else {
                return minus ? -num : num;
            }
            b = readByte();
        }
    }

    public long nextLong() {
        long num = 0;
        int b;
        boolean minus = false;
        while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
            ;
        if (b == '-') {
            minus = true;
            b = readByte();
        }

        while (true) {
            if (b >= '0' && b <= '9') {
                num = num * 10 + (b - '0');
            } else {
                return minus ? -num : num;
            }
            b = readByte();
        }
    }

}

class Input {
    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public Input(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream), 32768);
        tokenizer = null;
        tokenizer = null;
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return tokenizer.nextToken();
    }

    public String nextLine() {
        String s = "";
        try {
            s = reader.readLine();
        } catch (IOException e) {
            try {
                throw new IOException();
            } catch (IOException e1) {
                e1.printStackTrace();
            }
        }
        return s;
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }

    public long nextLong() {
        return Long.parseLong(next());
    }

    public double nextDouble() {
        return Double.parseDouble(next());
    }
}


import java.io.InputStreamReader;
import java.io.IOException;
import java.util.InputMismatchException;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.Reader;
import java.io.Writer;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 * @author Niyaz Nigmatullin
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		FastScanner in = new FastScanner(inputStream);
		FastPrinter out = new FastPrinter(outputStream);
		TaskA solver = new TaskA();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskA {

    static boolean ok(char[] c, int i) {
        if (i > 0 && c[i] == c[i - 1]) return false;
        if (i > 1 && c[i] == c[i - 2]) return false;
        return true;
    }

    public void solve(int testNumber, FastScanner in, FastPrinter out) {
        int n = in.nextInt();
        int p = in.nextInt();
        char[] c = in.next().toCharArray();
        for (int i = n - 1; i >= 0; i--) {
            char[] d = c.clone();
            all:
            for (int j = d[i] - 'a' + 1; j < p; j++) {
                d[i] = (char) ('a' + j);
                if (!ok(d, i)) {
                    continue;
                }
                for (int k = i + 1; k < n; k++) {
                    boolean found = false;
                    for (int letter = 0; letter < p; letter++) {
                        d[k] = (char) ('a' + letter);
                        if (ok(d, k)) {
                            found = true;
                            break;
                        }
                    }
                    if (!found) {
                        continue all;
                    }
                }
                out.println(d);
                return;
            }
        }
        out.println("NO");
    }
}

class FastScanner extends BufferedReader {

    public FastScanner(InputStream is) {
        super(new InputStreamReader(is));
    }

    public int read() {
        try {
            int ret = super.read();
//            if (isEOF && ret < 0) {
//                throw new InputMismatchException();
//            }
//            isEOF = ret == -1;
            return ret;
        } catch (IOException e) {
            throw new InputMismatchException();
        }
    }

    public String next() {
        StringBuilder sb = new StringBuilder();
        int c = read();
        while (isWhiteSpace(c)) {
            c = read();
        }
        if (c < 0) {
            return null;
        }
        while (c >= 0 && !isWhiteSpace(c)) {
            sb.appendCodePoint(c);
            c = read();
        }
        return sb.toString();
    }

    static boolean isWhiteSpace(int c) {
        return c >= 0 && c <= 32;
    }

    public int nextInt() {
        int c = read();
        while (isWhiteSpace(c)) {
            c = read();
        }
        int sgn = 1;
        if (c == '-') {
            sgn = -1;
            c = read();
        }
        int ret = 0;
        while (c >= 0 && !isWhiteSpace(c)) {
            if (c < '0' || c > '9') {
                throw new NumberFormatException("digit expected " + (char) c
                        + " found");
            }
            ret = ret * 10 + c - '0';
            c = read();
        }
        return ret * sgn;
    }

    public String readLine() {
        try {
            return super.readLine();
        } catch (IOException e) {
            return null;
        }
    }

}

class FastPrinter extends PrintWriter {

    public FastPrinter(OutputStream out) {
        super(out);
    }

    public FastPrinter(Writer out) {
        super(out);
    }

}


import java.io.*;
import java.util.*;

public class A {

    FastScanner in;
    PrintWriter out;

    void solve() {
        int n = in.nextInt(), k = in.nextInt();
        char[] c = in.nextToken().toCharArray();
        char max = (char) ('a' + k - 1);

        for (int pos = n - 1; pos >= 0; pos--) {
            char[] d = c.clone();
            char cur = (char) (d[pos] + 1);
            while (cur <= max) {
                if (pos - 1 >= 0 && d[pos - 1] == cur) {
                    cur++;
                    continue;
                }
                if (pos - 2 >= 0 && d[pos - 2] == cur) {
                    cur++;
                    continue;
                }

                d[pos] = cur;
                boolean ok = true;
                for (int t = pos + 1; t < n; t++) {
                    cur = 'a';
                    while (cur <= max) {
                        if (t - 1 >= 0 && d[t - 1] == cur) {
                            cur++;
                            continue;
                        }
                        if (t - 2 >= 0 && d[t - 2] == cur) {
                            cur++;
                            continue;
                        }
                        break;
                    }

                    if (cur > max) {
                        ok = false;
                        break;
                    }
                    d[t] = cur;
                }

                if (ok) {
                    out.println(new String(d));
                    return;
                }
            }
        }
        out.println("NO");
    }

    void run() {
        in = new FastScanner();
        out = new PrintWriter(System.out);
        solve();
        out.close();
    }

    class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        public FastScanner() {
            br = new BufferedReader(new InputStreamReader(System.in));
        }

        public FastScanner(String s) {
            try {
                br = new BufferedReader(new FileReader(s));
            } catch (FileNotFoundException e) {
                e.printStackTrace();
            }
        }

        String nextToken() {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }

        int nextInt() {
            return Integer.parseInt(nextToken());
        }

        long nextLong() {
            return Long.parseLong(nextToken());
        }

        double nextDouble() {
            return Double.parseDouble(nextToken());
        }
    }

    public static void main(String[] args) {
        new A().run();
    }
}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class NotoPalindromes {

  static BufferedReader in;
  static PrintWriter out;
  static StringTokenizer tok;

  static void solve() throws Exception {
    int n = nextInt(), p = nextInt();
    char[] c = next().toCharArray();
    char max = (char) ('a' - 1 + p);
    for (int i = n - 1; i >= 0; i--) {
      while (c[i] < max) {
        c[i]++;
        if ((i > 0 && c[i] == c[i - 1]) || (i > 1 && c[i] == c[i - 2]))
          continue;
        for (int j = i + 1; j < n; j++) {
          c[j] = 'a';
          if (c[j] > max)
            c[j] -= p;
          while ((j > 0 && c[j] == c[j - 1]) || (j > 1 && c[j] == c[j - 2])) {
            c[j]++;
            if (c[j] > max)
              c[j] -= p;
          }
        }
        out.println(new String(c));
        return;
      }
    }
    out.println("NO");
  }

  public static void main(String args[]) {
    try {
      in = new BufferedReader(new InputStreamReader(System.in));
      out = new PrintWriter(new OutputStreamWriter(System.out));
      solve();
      in.close();
      out.close();
    } catch (Throwable e) {
      e.printStackTrace();
      System.exit(1);
    }
  }

  static int nextInt() throws IOException {
    return Integer.parseInt(next());
  }

  static int[] nextIntArray(int len, int start) throws IOException {
    int[] a = new int[len];
    for (int i = start; i < len; i++)
      a[i] = nextInt();
    return a;
  }

  static long nextLong() throws IOException {
    return Long.parseLong(next());
  }

  static long[] nextLongArray(int len, int start) throws IOException {
    long[] a = new long[len];
    for (int i = start; i < len; i++)
      a[i] = nextLong();
    return a;
  }

  static String next() throws IOException {
    while (tok == null || !tok.hasMoreTokens()) {
      tok = new StringTokenizer(in.readLine());
    }
    return tok.nextToken();
  }

}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class NotoPalindromes {

  static BufferedReader in;
  static PrintWriter out;
  static StringTokenizer tok;

  static void solve() throws Exception {
    int n = nextInt(), p = nextInt();
    char[] c = next().toCharArray();
    char max = (char) ('a' - 1 + p);
    for (int i = n - 1; i >= 0; i--) {
      while (c[i] < max) {
        c[i]++;
        if ((i > 0 && c[i] == c[i - 1]) || (i > 1 && c[i] == c[i - 2]))
          continue;
        for (int j = i + 1; j < n; j++) {
          c[j] = (char) (c[j - 1] + 1);
          if (c[j] > max)
            c[j] -= p;
          while ((j > 0 && c[j] == c[j - 1]) || (j > 1 && c[j] == c[j - 2])) {
            c[j]++;
            if (c[j] > max)
              c[j] -= p;
          }
        }
        out.println(new String(c));
        return;
      }
    }
    out.println("NO");
  }

  public static void main(String args[]) {
    try {
      in = new BufferedReader(new InputStreamReader(System.in));
      out = new PrintWriter(new OutputStreamWriter(System.out));
      solve();
      in.close();
      out.close();
    } catch (Throwable e) {
      e.printStackTrace();
      System.exit(1);
    }
  }

  static int nextInt() throws IOException {
    return Integer.parseInt(next());
  }

  static int[] nextIntArray(int len, int start) throws IOException {
    int[] a = new int[len];
    for (int i = start; i < len; i++)
      a[i] = nextInt();
    return a;
  }

  static long nextLong() throws IOException {
    return Long.parseLong(next());
  }

  static long[] nextLongArray(int len, int start) throws IOException {
    long[] a = new long[len];
    for (int i = start; i < len; i++)
      a[i] = nextLong();
    return a;
  }

  static String next() throws IOException {
    while (tok == null || !tok.hasMoreTokens()) {
      tok = new StringTokenizer(in.readLine());
    }
    return tok.nextToken();
  }

}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class NotoPalindromes {

  static BufferedReader in;
  static PrintWriter out;
  static StringTokenizer tok;

  static void solve() throws Exception {
    int n = nextInt(), p = nextInt();
    char[] c = next().toCharArray();
    for (int i = n - 1; i >= 2; i--) {
      c[i]++;
      while (c[i] == c[i - 1] || c[i] == c[i - 2])
        c[i]++;
      if (c[i] - 'a' < p) {
        out.println(new String(c));
        return;
      }
      c[i] -= p;
    }
    if (n > 1) {
      c[1]++;
      while (c[1] == c[0])
        c[1]++;
      if (c[1] - 'a' < p) {
        out.println(new String(c));
        return;
      }
      c[1] -= p;
    }
    c[0]++;
    out.println(c[0] - 'a' < p ? new String(c) : "NO");
  }

  public static void main(String args[]) {
    try {
      in = new BufferedReader(new InputStreamReader(System.in));
      out = new PrintWriter(new OutputStreamWriter(System.out));
      solve();
      in.close();
      out.close();
    } catch (Throwable e) {
      e.printStackTrace();
      System.exit(1);
    }
  }

  static int nextInt() throws IOException {
    return Integer.parseInt(next());
  }

  static int[] nextIntArray(int len, int start) throws IOException {
    int[] a = new int[len];
    for (int i = start; i < len; i++)
      a[i] = nextInt();
    return a;
  }

  static long nextLong() throws IOException {
    return Long.parseLong(next());
  }

  static long[] nextLongArray(int len, int start) throws IOException {
    long[] a = new long[len];
    for (int i = start; i < len; i++)
      a[i] = nextLong();
    return a;
  }

  static String next() throws IOException {
    while (tok == null || !tok.hasMoreTokens()) {
      tok = new StringTokenizer(in.readLine());
    }
    return tok.nextToken();
  }

}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.util.StringTokenizer;

public class NotoPalindromes {

  static BufferedReader in;
  static PrintWriter out;
  static StringTokenizer tok;

  static void solve() throws Exception {
    int n = nextInt(), p = nextInt();
    char[] c = next().toCharArray();
    char max = (char) ('a' - 1 + p);
    for (int i = n - 1; i >= 0; i--) {
      while (c[i] < max) {
        c[i]++;
        if ((i > 0 && c[i] == c[i - 1]) || (i > 1 && c[i] == c[i - 2]))
          continue;
        for (int j = i + 1; j < n; j++) {
          c[j] = (char) (c[i] + j - i);
          if (c[j] > max)
            c[j] -= p;
        }
        out.println(new String(c));
        return;
      }
    }
    out.println("NO");
  }

  public static void main(String args[]) {
    try {
      in = new BufferedReader(new InputStreamReader(System.in));
      out = new PrintWriter(new OutputStreamWriter(System.out));
      solve();
      in.close();
      out.close();
    } catch (Throwable e) {
      e.printStackTrace();
      System.exit(1);
    }
  }

  static int nextInt() throws IOException {
    return Integer.parseInt(next());
  }

  static int[] nextIntArray(int len, int start) throws IOException {
    int[] a = new int[len];
    for (int i = start; i < len; i++)
      a[i] = nextInt();
    return a;
  }

  static long nextLong() throws IOException {
    return Long.parseLong(next());
  }

  static long[] nextLongArray(int len, int start) throws IOException {
    long[] a = new long[len];
    for (int i = start; i < len; i++)
      a[i] = nextLong();
    return a;
  }

  static String next() throws IOException {
    while (tok == null || !tok.hasMoreTokens()) {
      tok = new StringTokenizer(in.readLine());
    }
    return tok.nextToken();
  }

}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Comparator;
import java.util.List;
import java.util.InputMismatchException;

public class Main {

    IIO io;

    Main(IIO io) {
        this.io = io;
    }

    public static void main(String[] args) throws IOException {

        ConsoleIO io = new ConsoleIO();
        Main m = new Main(io);
        m.solve();
        io.flush();

//        Tester test = new Tester();test.run();
    }

    public void solve() {
        int[] l = io.readIntArray();
        int n = l[0];
        int p = l[1];
        char[] s = io.readLine().toCharArray();
        int maxC = 'a' + p - 1;
        for (int i = n - 1; i >= 0; i--) {
            for (int c = s[i] + 1; c <= maxC; c++) {
                if ((i < 2 || s[i - 2] != c) && (i < 1 || s[i - 1] != c)) {
                    s[i] = (char) c;
                    for (int k = i + 1; k < n; k++) {
                        for (int c2 = 'a'; c2 <= maxC; c2++)
                            if ((k < 2 || s[k - 2] != c2) && (k < 1 || s[k - 1] != c2)) {
                                s[k] = (char) c2;
                                break;
                            }
                    }
                    io.writeLine(new String(s));
                    return;
                }
            }
        }
        io.writeLine("NO");
    }

}

class ConsoleIO extends BaseIO {
    BufferedReader br;
    PrintWriter out;
    public ConsoleIO(){
        br = new BufferedReader(new InputStreamReader(System.in));
        out = new PrintWriter(System.out);
    }
    public void flush(){
        this.out.close();
    }
    public void writeLine(String s) {
        this.out.println(s);
    }
    public void writeInt(int a) {
        this.out.print(a);
        this.out.print(' ');
    }
    public void writeWord(String s){
        this.out.print(s);
    }
    public String readLine() {
        try {
            return br.readLine();
        }
        catch (Exception ex){
            return "";
        }
    }
    public int read(){
        try {
            return br.read();
        }
        catch (Exception ex){
            return -1;
        }
    }
}
abstract class BaseIO implements IIO {

    public long readLong() {
        return Long.parseLong(this.readLine());
    }

    public int readInt() {
        return Integer.parseInt(this.readLine());
    }

    public int[] readIntArray() {
        String line = this.readLine();
        String[] nums = line.split(" ");
        int[] res = new int[nums.length];
        for (int i = 0; i < nums.length; i++) {
            res[i] = Integer.parseInt(nums[i]);
        }
        return res;
    }
    public long[] readLongArray() {
        String line = this.readLine();
        String[] nums = line.split(" ");
        long[] res = new long[nums.length];
        for (int i = 0; i < nums.length; i++) {
            res[i] = Long.parseLong(nums[i]);
        }
        return res;
    }
}
interface IIO {
    void writeLine(String s);
    void writeInt(int a);
    void writeWord(String s);
    String readLine();
    long readLong();
    int readInt();
    int read();
    int[] readIntArray();
    long[] readLongArray();
}


import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.IOException;
import java.util.StringTokenizer;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 * @author Rubanenko
 */
public class Main {
	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(inputStream);
		PrintWriter out = new PrintWriter(outputStream);
		TaskA solver = new TaskA();
		solver.solve(1, in, out);
		out.close();
	}
}

class TaskA {

    String s;
    int n, p;
    boolean found;
    char[] a;
    public void solve(int testNumber, InputReader in, PrintWriter out) {
        n = in.nextInt();
        p = in.nextInt();
        s = in.next();
        found = false;
        a = new char[n + 1];
        for (int i = n - 1; i >= 0; i--) {
            for (int j = 0; j < n; j++) {
                a[j] = s.charAt(j);
            }
            for (char j = s.charAt(i); j < (char)p + 'a'; j++) {
                if (j == s.charAt(i)) continue;
                if (i > 0 && j == a[i - 1]) continue;
                if (i > 1 && j == a[i - 2]) continue;
                a[i] = j;
                boolean can = true;
                for (int u = i + 1; u < n; u++) {
                    boolean ok = false;
                    for (char q = 'a'; q < (char)p + 'a'; q++) {
                        if (u > 0 && q == a[u - 1]) continue;
                        if (u > 1 && q == a[u - 2]) continue;
                        ok = true;
                        a[u] = q;
                        break;
                    }
                    if (!ok) {
                        can = false;
                        break;
                    }
                }
                if (can) {
                    for (int u = 0; u < n; u++) {
                        out.print(a[u]);
                    }
                    out.println();
                    return;
                }
            }
        }
        out.println("NO");
    }
}

class InputReader {
    private BufferedReader reader;
    private StringTokenizer tokenizer;

    public InputReader(InputStream inputStream) {
        reader = new BufferedReader(new InputStreamReader(inputStream));
    }

    public String nextLine() {
        String line = null;
        try {
            line = reader.readLine();
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
        return line;
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens())
            tokenizer = new StringTokenizer(nextLine());
        return tokenizer.nextToken();
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }
}


/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author dipankar12
 */
import java.io.*;
import java.util.*;
public class r265a {
    public static void main(String args[])
    {
        fastio in=new fastio(System.in);
        PrintWriter pw=new PrintWriter(System.out);

        int n=in.nextInt();
        int p=in.nextInt();
        char ar[]=in.readString().toCharArray();

        if(p==1)
        {
            pw.println("NO");
            pw.close();
            return;
        }

        String ans="NO";
        int anspos=-1,ansval=-1;
        loop:   for(int i=n-1;i>=0;i--)
                {
                    int pos=n-1-i;
                    int j=ar[i]-'a';
                    j++;
                    //pw.println(i+" "+pos+" "+j);
                    int q=0;
                    for(;j<p;j++)
                    {
                        q++;
                        //pw.println(j+" "+q);
                        if((char)(ar[i]-'a'+q+97)!=ar[pos]||(char)(ar[i]-'a'+q+97)==ar[pos]&&Math.abs(pos-i)!=2)
                        {
                            if(i-1>=0&&ar[i-1]!=(char)(ar[i]-'a'+q+97))
                            {
                                //pw.println("x");
                                anspos=i;
                                ansval=q;
                                break loop;
                            }
                            else if(i-1<0)
                            {
                                //pw.println("x");
                                anspos=i;
                                ansval=q;
                                break loop;
                            }
                        }
                    }
                }

        //pw.println(anspos+" ans "+ansval);
        if(anspos==-1)
            pw.println(ans);
        else
        {
            ar[anspos]=(char)(ar[anspos]-'a'+ansval+97);
            int j=0;
            for(int i=anspos+1;i<n;i++)
            {
                if(i-1>=0&&ar[i-1]==(char)(97+j))
                {
                    j++;
                    j%=p;
                    i--;
                }
                else if(i-2>=0&&ar[i-2]==(char)(97+j))
                {
                    j++;
                    j%=p;
                    i--;
                }
                else
                {
                    ar[i]=(char)(j+97);
                    j++;
                    j%=p;
                }
            }

            for(char i:ar)
                pw.print(i);
        }
        pw.close();
    }

    static class fastio {

            private final InputStream stream;
            private final byte[] buf = new byte[8192];
            private int cchar, snchar;
            private SpaceCharFilter filter;

            public fastio(InputStream stream) {
                this.stream = stream;
            }

            public int nxt() {
                if (snchar == -1)
                    throw new InputMismatchException();
                if (cchar >= snchar) {
                    cchar = 0;
                    try {
                        snchar = stream.read(buf);
                    } catch (IOException e) {
                        throw new InputMismatchException();
                    }
                    if (snchar <= 0)
                        return -1;
                }
                return buf[cchar++];
            }

            public int nextInt() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                int sgn = 1;
                if (c == '-') {
                    sgn = -1;
                    c = nxt();
                }
                int res = 0;
                do {
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    res *= 10;
                    res += c - '0';
                    c = nxt();
                } while (!isSpaceChar(c));
                return res * sgn;
            }

            public long nextLong() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                int sgn = 1;
                if (c == '-') {
                    sgn = -1;
                    c = nxt();
                }
                long res = 0;
                do {
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    res *= 10;
                    res += c - '0';
                    c = nxt();
                } while (!isSpaceChar(c));
                return res * sgn;
            }

            public int[] nextIntArray(int n) {
                int a[] = new int[n];
                for (int i = 0; i < n; i++) {
                    a[i] = nextInt();
                }
                return a;
            }

            public String readString() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                StringBuilder res = new StringBuilder();
                do {
                    res.appendCodePoint(c);
                    c = nxt();
                } while (!isSpaceChar(c));
                return res.toString();
            }

            public String nextLine() {
                int c = nxt();
                while (isSpaceChar(c))
                    c = nxt();
                StringBuilder res = new StringBuilder();
                do {
                    res.appendCodePoint(c);
                    c = nxt();
                } while (!isEndOfLine(c));
                return res.toString();
            }

            public boolean isSpaceChar(int c) {
                if (filter != null)
                    return filter.isSpaceChar(c);
                return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
            }

            private boolean isEndOfLine(int c) {
                return c == '\n' || c == '\r' || c == -1;
            }

            public interface SpaceCharFilter {
                public boolean isSpaceChar(int ch);
            }
        }

}


/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author dipankar12
 */
import java.io.*;
import java.util.*;
public class r265a {
    public static void main(String args[])
    {
        fastio in=new fastio(System.in);
        PrintWriter pw=new PrintWriter(System.out);

        int n=in.nextInt();
        int p=in.nextInt();
        char ar[]=in.readString().toCharArray();

        if(p==1||p==2)
        {
            pw.println("NO");
            pw.close();
            return;
        }

        String ans="NO";
        int anspos=-1,ansval=-1;
        loop:   for(int i=n-1;i>=0;i--)
                {
                    int pos=n-1-i;
                    int j=ar[i]-'a';
                    j++;
                    //pw.println(i+" "+pos+" "+j);
                    int q=0;
                    for(;j<p;j++)
                    {
                        q++;
                        //pw.println(j+" "+q);
                        if((char)(ar[i]-'a'+q+97)!=ar[pos]||(char)(ar[i]-'a'+q+97)==ar[pos]&&Math.abs(pos-i)!=2)
                        {
                            if(i-1>=0&&ar[i-1]!=(char)(ar[i]-'a'+q+97))
                            {
                                //pw.println("x");
                                anspos=i;
                                ansval=q;
                                break loop;
                            }
                            else if(i-1<0)
                            {
                                pw.println("x");
                                anspos=i;
                                ansval=q;
                                break loop;
                            }
                        }
                    }
                }

        //pw.println(anspos+" ans "+ansval);
        if(anspos==-1)
            pw.println(ans);
        else
        {
            ar[anspos]=(char)(ar[anspos]-'a'+ansval+97);
            int j=0;
            for(int i=anspos+1;i<n;i++)
            {
                if(i-1>=0&&ar[i-1]==(char)(97+j))
                {
                    j++;
                    j%=p;
                    i--;
                }
                else if(i-2>=0&&ar[i-2]==(char)(97+j))
                {
                    j++;
                    j%=p;
                    i--;
                }
                else
                {
                    ar[i]=(char)(j+97);
                    j++;
                    j%=p;
                }
            }

            for(char i:ar)
                pw.print(i);
        }
        pw.close();
    }

    static class fastio {

            private final InputStream stream;
            private final byte[] buf = new byte[8192];
            private int cchar, snchar;
            private SpaceCharFilter filter;

            public fastio(InputStream stream) {
                this.stream = stream;
            }

            public int nxt() {
                if (snchar == -1)
                    throw new InputMismatchException();
                if (cchar >= snchar) {
                    cchar = 0;
                    try {
                        snchar = stream.read(buf);
                    } catch (IOException e) {
                        throw new InputMismatchException();
                    }
                    if (snchar <= 0)
                        return -1;
                }
                return buf[cchar++];
            }

            public int nextInt() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                int sgn = 1;
                if (c == '-') {
                    sgn = -1;
                    c = nxt();
                }
                int res = 0;
                do {
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    res *= 10;
                    res += c - '0';
                    c = nxt();
                } while (!isSpaceChar(c));
                return res * sgn;
            }

            public long nextLong() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                int sgn = 1;
                if (c == '-') {
                    sgn = -1;
                    c = nxt();
                }
                long res = 0;
                do {
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    res *= 10;
                    res += c - '0';
                    c = nxt();
                } while (!isSpaceChar(c));
                return res * sgn;
            }

            public int[] nextIntArray(int n) {
                int a[] = new int[n];
                for (int i = 0; i < n; i++) {
                    a[i] = nextInt();
                }
                return a;
            }

            public String readString() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                StringBuilder res = new StringBuilder();
                do {
                    res.appendCodePoint(c);
                    c = nxt();
                } while (!isSpaceChar(c));
                return res.toString();
            }

            public String nextLine() {
                int c = nxt();
                while (isSpaceChar(c))
                    c = nxt();
                StringBuilder res = new StringBuilder();
                do {
                    res.appendCodePoint(c);
                    c = nxt();
                } while (!isEndOfLine(c));
                return res.toString();
            }

            public boolean isSpaceChar(int c) {
                if (filter != null)
                    return filter.isSpaceChar(c);
                return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
            }

            private boolean isEndOfLine(int c) {
                return c == '\n' || c == '\r' || c == -1;
            }

            public interface SpaceCharFilter {
                public boolean isSpaceChar(int ch);
            }
        }

}


/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author dipankar12
 */
import java.io.*;
import java.util.*;
public class r265a {
    public static void main(String args[])
    {
        fastio in=new fastio(System.in);
        PrintWriter pw=new PrintWriter(System.out);

        int n=in.nextInt();
        int p=in.nextInt();
        char ar[]=in.readString().toCharArray();

        if(p==1)
        {
            pw.println("NO");
            pw.close();
            return;
        }

        String ans="NO";
        int anspos=-1,ansval=-1;
        loop:   for(int i=n-1;i>=0;i--)
                {
                    int pos=n-1-i;
                    int j=ar[i]-'a';
                    j++;
                    //pw.println(i+" "+pos+" "+j);
                    int q=0;
                    for(;j<p;j++)
                    {
                        q++;
                        //pw.println(j+" "+q);
                        if(i-2>=0&&ar[i-2]!=(char)(ar[i]-'a'+97+q)||i-2<0&&i-1>=0||i==0)
                        {
                            if(i-1>=0&&ar[i-1]!=(char)(ar[i]-'a'+q+97))
                            {
                                //pw.println("x");
                                anspos=i;
                                ansval=q;
                                break loop;
                            }
                            else if(i-1<0)
                            {
                                //pw.println("x");
                                anspos=i;
                                ansval=q;
                                break loop;
                            }
                        }
                    }
                }

        //pw.println(anspos+" ans "+ansval);
        if(anspos==-1)
            pw.println(ans);
        else
        {
            ar[anspos]=(char)(ar[anspos]-'a'+ansval+97);
            int j=0;
            for(int i=anspos+1;i<n;i++)
            {
                if(i-1>=0&&ar[i-1]==(char)(97+j))
                {
                    j++;
                    j%=p;
                    i--;
                }
                else if(i-2>=0&&ar[i-2]==(char)(97+j))
                {
                    j++;
                    j%=p;
                    i--;
                }
                else
                {
                    ar[i]=(char)(j+97);
                    j++;
                    j%=p;
                }
            }

            for(char i:ar)
                pw.print(i);
        }
        pw.close();
    }

    static class fastio {

            private final InputStream stream;
            private final byte[] buf = new byte[8192];
            private int cchar, snchar;
            private SpaceCharFilter filter;

            public fastio(InputStream stream) {
                this.stream = stream;
            }

            public int nxt() {
                if (snchar == -1)
                    throw new InputMismatchException();
                if (cchar >= snchar) {
                    cchar = 0;
                    try {
                        snchar = stream.read(buf);
                    } catch (IOException e) {
                        throw new InputMismatchException();
                    }
                    if (snchar <= 0)
                        return -1;
                }
                return buf[cchar++];
            }

            public int nextInt() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                int sgn = 1;
                if (c == '-') {
                    sgn = -1;
                    c = nxt();
                }
                int res = 0;
                do {
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    res *= 10;
                    res += c - '0';
                    c = nxt();
                } while (!isSpaceChar(c));
                return res * sgn;
            }

            public long nextLong() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                int sgn = 1;
                if (c == '-') {
                    sgn = -1;
                    c = nxt();
                }
                long res = 0;
                do {
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    res *= 10;
                    res += c - '0';
                    c = nxt();
                } while (!isSpaceChar(c));
                return res * sgn;
            }

            public int[] nextIntArray(int n) {
                int a[] = new int[n];
                for (int i = 0; i < n; i++) {
                    a[i] = nextInt();
                }
                return a;
            }

            public String readString() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                StringBuilder res = new StringBuilder();
                do {
                    res.appendCodePoint(c);
                    c = nxt();
                } while (!isSpaceChar(c));
                return res.toString();
            }

            public String nextLine() {
                int c = nxt();
                while (isSpaceChar(c))
                    c = nxt();
                StringBuilder res = new StringBuilder();
                do {
                    res.appendCodePoint(c);
                    c = nxt();
                } while (!isEndOfLine(c));
                return res.toString();
            }

            public boolean isSpaceChar(int c) {
                if (filter != null)
                    return filter.isSpaceChar(c);
                return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
            }

            private boolean isEndOfLine(int c) {
                return c == '\n' || c == '\r' || c == -1;
            }

            public interface SpaceCharFilter {
                public boolean isSpaceChar(int ch);
            }
        }

}


/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author dipankar12
 */
import java.io.*;
import java.util.*;
public class r265a {
    public static void main(String args[])
    {
        fastio in=new fastio(System.in);
        PrintWriter pw=new PrintWriter(System.out);

        int n=in.nextInt();
        int p=in.nextInt();
        char ar[]=in.readString().toCharArray();

        if(p==1)
        {
            pw.println("NO");
            pw.close();
            return;
        }

        String ans="NO";
        int anspos=-1,ansval=-1;
        loop:   for(int i=n-1;i>=0;i--)
                {
                    int pos=n-1-i;
                    int j=ar[i]-'a';
                    j++;
                    //pw.println(i+" "+pos+" "+j);
                    int q=0;
                    for(;j<p;j++)
                    {
                        q++;
                        //pw.println(j+" "+q);
                        if(i-2>=0&&ar[i-2]!=(char)(ar[i]-'a'+97+q)||i-2<0&&i-1>=0||i==0)
                        {
                            if(i-1>=0&&ar[i-1]!=(char)(ar[i]-'a'+q+97))
                            {
                                //pw.println("x");
                                anspos=i;
                                ansval=q;
                                break loop;
                            }
                            else if(i-1<0)
                            {
                                //pw.println("x");
                                anspos=i;
                                ansval=q;
                                break loop;
                            }
                        }
                    }
                }

        //pw.println(anspos+" ans "+ansval);
        if(anspos==-1)
            pw.println(ans);
        else
        {
            ar[anspos]=(char)(ar[anspos]-'a'+ansval+97);
            for(int i=anspos+1;i<n;i++)
            {
                for(int j=0;j<26;j++)
                {
                    if(i-1>=0&&ar[i-1]==(char)(97+j))
                    {
                        continue;
                    }
                    else if(i-2>=0&&ar[i-2]==(char)(97+j))
                    {
                        continue;
                    }
                    else
                    {
                        ar[i]=(char)(j+97);
                        break;
                    }
                }
            }

            for(char i:ar)
                pw.print(i);
        }
        pw.close();
    }

    static class fastio {

            private final InputStream stream;
            private final byte[] buf = new byte[8192];
            private int cchar, snchar;
            private SpaceCharFilter filter;

            public fastio(InputStream stream) {
                this.stream = stream;
            }

            public int nxt() {
                if (snchar == -1)
                    throw new InputMismatchException();
                if (cchar >= snchar) {
                    cchar = 0;
                    try {
                        snchar = stream.read(buf);
                    } catch (IOException e) {
                        throw new InputMismatchException();
                    }
                    if (snchar <= 0)
                        return -1;
                }
                return buf[cchar++];
            }

            public int nextInt() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                int sgn = 1;
                if (c == '-') {
                    sgn = -1;
                    c = nxt();
                }
                int res = 0;
                do {
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    res *= 10;
                    res += c - '0';
                    c = nxt();
                } while (!isSpaceChar(c));
                return res * sgn;
            }

            public long nextLong() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                int sgn = 1;
                if (c == '-') {
                    sgn = -1;
                    c = nxt();
                }
                long res = 0;
                do {
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    res *= 10;
                    res += c - '0';
                    c = nxt();
                } while (!isSpaceChar(c));
                return res * sgn;
            }

            public int[] nextIntArray(int n) {
                int a[] = new int[n];
                for (int i = 0; i < n; i++) {
                    a[i] = nextInt();
                }
                return a;
            }

            public String readString() {
                int c = nxt();
                while (isSpaceChar(c)) {
                    c = nxt();
                }
                StringBuilder res = new StringBuilder();
                do {
                    res.appendCodePoint(c);
                    c = nxt();
                } while (!isSpaceChar(c));
                return res.toString();
            }

            public String nextLine() {
                int c = nxt();
                while (isSpaceChar(c))
                    c = nxt();
                StringBuilder res = new StringBuilder();
                do {
                    res.appendCodePoint(c);
                    c = nxt();
                } while (!isEndOfLine(c));
                return res.toString();
            }

            public boolean isSpaceChar(int c) {
                if (filter != null)
                    return filter.isSpaceChar(c);
                return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
            }

            private boolean isEndOfLine(int c) {
                return c == '\n' || c == '\r' || c == -1;
            }

            public interface SpaceCharFilter {
                public boolean isSpaceChar(int ch);
            }
        }

}