You are given a string S of length n with each character being one of the first m lowercase English letters. 

Calculate how many different strings T of length n composed from the first m lowercase English letters exist such that the length of LCS (longest common subsequence) between S and T is n - 1.

Recall that LCS of two strings S and T is the longest string C such that C both in S and T as a subsequence.

Input

The first line contains two numbers n and m denoting the length of string S and number of first English lowercase characters forming the character set for strings (1 ≤ n ≤ 100 000, 2 ≤ m ≤ 26).

The second line contains string S.

Output

Print the only line containing the answer.

Examples

Input

3 3
aaa


Output

6


Input

3 3
aab


Output

11


Input

1 2
a


Output

1


Input

10 9
abacadefgh


Output

789

Note

For the first sample, the 6 possible strings T are: aab, aac, aba, aca, baa, caa. 

For the second sample, the 11 possible strings T are: aaa, aac, aba, abb, abc, aca, acb, baa, bab, caa, cab.

For the third sample, the only possible string T is b.
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.StringTokenizer;

/*
3 3
abc

3 3
aab

10 26
abcdefghijklmnopqrstvwxyz

 */
public class P578D
{
	static int m;
	static long[][][][] dp;
	static char[] s;
	public static void main(String[] args)
	{
		FastScanner scan = new FastScanner();
		scan.nextInt();
		m = scan.nextInt();
		s = scan.next().toCharArray();
		dp = new long[2][3][4][s.length];
		for (long[][][] a : dp)
			for (long[][] b : a)
				for (long[] c : b)
					Arrays.fill(c, -1);
		
		System.out.println(go(0, 0, 0, 0));
	}
	private static long go(int ind, int behind, int skipped, int also)
	{
		if (behind >= 2 || behind <= -2)
			return 0;
		if (ind >= s.length)
			return skipped == 1 && behind != -1 || skipped == 0 && behind == -1 ? 1 : 0;
		if (behind-also <= -2)
			also = 0;
		if (dp[skipped][also][behind+1][ind] >= 0)
			return dp[skipped][also][behind+1][ind];
		long ans = 0;
		char curr = ind+behind < s.length ? s[ind+behind] : ' ';
		char next = ind+behind+1 < s.length ? s[ind+behind+1] : ' ';
		for (char c = 'a'; c < 'a'+m; c++)
		{
			if (also != 0)
			{
				//Skipped should be true for the right pointer and false for the left
				char right = curr;
				char left = ind+behind-also < s.length ? s[ind+behind-also] : ' ';
				if (c == right && c == left)
					ans += go(ind+1, behind, skipped, also);
				else if (c == right)
					ans += go(ind+1, behind, skipped, 0);
				else if (c == left)
					ans += go(ind+1, behind-also, 0, 0);
				else
					ans += go(ind+1, behind-1, skipped, 0);
			}
			else if (c == curr)
				ans += go(ind+1, behind, skipped, 0);
			else if (c == next && skipped == 0)
				ans += go(ind+1, behind+1, 1, 2);
			else
				ans += go(ind+1, behind-1, skipped, 0);
		}
		
		return dp[skipped][also][behind+1][ind] = ans;
	}
	
	static class FastScanner
	{
		BufferedReader r;
		StringTokenizer t;

		FastScanner()
		{
			r = new BufferedReader(new InputStreamReader(System.in));
			t = new StringTokenizer("");
		}

		String next()
		{
			while (!t.hasMoreElements())
				try
				{
					t = new StringTokenizer(r.readLine());
				} catch (IOException e)
				{
					e.printStackTrace();
				}
			return t.nextToken();
		}

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

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