You want to perform the combo on your opponent in one popular fighting game. The combo is the string s consisting of n lowercase Latin letters. To perform the combo, you have to press all buttons in the order they appear in s. I.e. if s="abca" then you have to press 'a', then 'b', 'c' and 'a' again.

You know that you will spend m wrong tries to perform the combo and during the i-th try you will make a mistake right after p_i-th button (1 ≤ p_i < n) (i.e. you will press first p_i buttons right and start performing the combo from the beginning). It is guaranteed that during the m+1-th try you press all buttons right and finally perform the combo.

I.e. if s="abca", m=2 and p = [1, 3] then the sequence of pressed buttons will be 'a' (here you're making a mistake and start performing the combo from the beginning), 'a', 'b', 'c', (here you're making a mistake and start performing the combo from the beginning), 'a' (note that at this point you will not perform the combo because of the mistake), 'b', 'c', 'a'.

Your task is to calculate for each button (letter) the number of times you'll press it.

You have to answer t independent test cases.

Input

The first line of the input contains one integer t (1 ≤ t ≤ 10^4) — the number of test cases.

Then t test cases follow.

The first line of each test case contains two integers n and m (2 ≤ n ≤ 2 ⋅ 10^5, 1 ≤ m ≤ 2 ⋅ 10^5) — the length of s and the number of tries correspondingly.

The second line of each test case contains the string s consisting of n lowercase Latin letters.

The third line of each test case contains m integers p_1, p_2, ..., p_m (1 ≤ p_i < n) — the number of characters pressed right during the i-th try.

It is guaranteed that the sum of n and the sum of m both does not exceed 2 ⋅ 10^5 (∑ n ≤ 2 ⋅ 10^5, ∑ m ≤ 2 ⋅ 10^5).

It is guaranteed that the answer for each letter does not exceed 2 ⋅ 10^9.

Output

For each test case, print the answer — 26 integers: the number of times you press the button 'a', the number of times you press the button 'b', ..., the number of times you press the button 'z'.

Example

Input


3
4 2
abca
1 3
10 5
codeforces
2 8 3 2 9
26 10
qwertyuioplkjhgfdsazxcvbnm
20 10 1 2 3 5 10 5 9 4


Output


4 2 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 
0 0 9 4 5 3 0 0 0 0 0 0 0 0 9 0 0 3 1 0 0 0 0 0 0 0 
2 1 1 2 9 2 2 2 5 2 2 2 1 1 5 4 11 8 2 7 5 1 10 1 5 2 

Note

The first test case is described in the problem statement. Wrong tries are "a", "abc" and the final try is "abca". The number of times you press 'a' is 4, 'b' is 2 and 'c' is 2.

In the second test case, there are five wrong tries: "co", "codeforc", "cod", "co", "codeforce" and the final try is "codeforces". The number of times you press 'c' is 9, 'd' is 4, 'e' is 5, 'f' is 3, 'o' is 9, 'r' is 3 and 's' is 1.
2
2 2
yz
1 1
2 2
yz
1 1
 1
11 2
thisisatest
3 5

0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 3 1 

0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 3 1 

 1 0 0 0 1 0 0 3 5 0 0 0 0 0 0 0 0 0 4 5 0 0 0 0 0 0 


   //      package com.company;
        import java.io.BufferedReader;
        import java.io.IOException;
        import java.io.InputStreamReader;
        import java.lang.reflect.Array;
        import java.sql.SQLOutput;
        import java.util.*;
        public class Main {

            public static void main(String[] args) throws IOException {
                Scanner s = new Scanner(System.in);
                //BufferedReader s=new BufferedReader(new InputStreamReader(System.in));
                 StringBuilder sb1 = new StringBuilder();//int n=Integer.parseInt(s.readLine());
                 int t=s.nextInt();
                 while(t-->0){
                     int n=s.nextInt();
                     int m=s.nextInt();
                     char[] a=s.next().toCharArray();
                     int[] p=new int[m];int[] fur=new int[n+1];
                     int[] oc=new int[123];
                      for(int i=0;i<n;i++) oc[a[i]]++;
                     for(int i=0;i<m;i++){
                         p[i]=s.nextInt();
                         fur[p[i]]++;
                     }
                     Arrays.sort(p);int j=0;
                     int val=m;int[] count=new int[123];
                     for(int i=0;i<n;i++){
                         val-=fur[i];
                         count[a[i]]+=val;
                     }
                     for(int i=97;i<123;i++){
                         sb1.append((count[i]+oc[i])+" ");
                     }sb1.append("\n");

                 }
                System.out.println(sb1.toString());

            }static int min=Integer.MAX_VALUE;static long ans=0;static long count=0;
            static void dfs(int i,int[] vis,HashMap<Integer,Integer> h,int [] a,int[] c,int ts){
              //if(vis[i]!= vis1[i]) return;
                if(vis[i]>0&&(!h.containsKey(i)||h.get(i)!=vis[i])) return;

                if(vis[i]==2) return;
                if(h.containsKey(i)&&h.get(i)==2) return;
                if(h.containsKey(i))  h.put(i,h.get(i)+1);
                else h.put(i,1);
                vis[i]+=1;
                //vis1[i]+=1;
                if(h.get(i)==2) min=Math.min(min,c[i])    ;
            //    if(vis[i]==1) min=c[i];
                dfs(a[i],vis,h,a,c,ts);
            }
            static  void computeLPSArray(String pat, int M, int lps[])
            {
            int len = 0;
                int i = 1;
                lps[0] = 0;
                while (i < M) {
                    if (pat.charAt(i) == pat.charAt(len)) {
                        len++;
                        lps[i] = len;
                        i++;
                    }
                    else // (pat[i] != pat[len])
                    {
                        if (len != 0) {
                            len = lps[len - 1];
                        }
                        else // if (len == 0)
                        {
                            lps[i] = len;
                            i++;
                        }
                    }
                }
            }
            static boolean isPrime(int n)
            {
                if (n <= 1) return false;
                if (n <= 3) return true;

                if (n % 2 == 0 || n % 3 == 0) return false;

                for (int i = 5; i * i <= n; i = i + 6)
                    if (n % i == 0 || n % (i + 2) == 0)
                        return false;

                return true;
            }

            static double power(double x, long y, int p) {
                double res = 1;
                x = x % p;
                while (y > 0) {
                    if ((y & 1) == 1)
                        res = (res * x) % p;
                    y = y >> 1;
                    x = (x * x) % p;
                }
                return res;
            }
            public static void fracion(double x) {
                String a = "" + x;
                String spilts[] = a.split("\\."); // split using decimal
                int b = spilts[1].length(); // find the decimal length
                int denominator = (int) Math.pow(10, b); // calculate the denominator
                int numerator = (int) (x * denominator); // calculate the nerumrator Ex
                // 1.2*10 = 12
                int gcd = (int)gcd((long)numerator, denominator); // Find the greatest common
                // divisor bw them
                String fraction = "" + numerator / gcd + "/" + denominator / gcd;
                // System.out.println((denominator/gcd));
                long x1=modInverse(denominator / gcd,998244353  );
                //  System.out.println(x1);
                System.out.println((((numerator / gcd )%998244353 *(x1%998244353  ))%998244353  ) );
            }static int anst=Integer.MAX_VALUE;
          static StringBuilder sb1=new StringBuilder();
            public static int bfs(int i1, ArrayList<Integer>[] h, int[] vis, int n,int val1) {
                Queue<Integer> q = new LinkedList<Integer>();
                q.add(i1);Queue<Integer> aq=new LinkedList<Integer>();
                aq.add(0);
                while(!q.isEmpty()){
                    int i=q.poll();
                    int val=aq.poll();
                    if(i==n){
                        return val;
                    }
                    if(h[i]!=null){
                        for(Integer j:h[i]){
                           if(vis[j]==0){
                            q.add(j);vis[j]=1;
                               aq.add(val+1);}
                        }
                    }
                }return -1;
            }
            static int i(String a) {
                return Integer.parseInt(a);
            }
            static long l(String a) {
                return Long.parseLong(a);
            }
            static String[] inp() throws IOException {
                BufferedReader s = new BufferedReader(new InputStreamReader(System.in));
                return s.readLine().trim().split("\\s+");
            }


            static long gcd(long a, long b) {
                if (b == 0)
                    return a;
                return gcd(b, a % b);
            }
            static long modInverse(int a, int m)
            {


                {
                    // If a and m are relatively prime, then modulo inverse
                    // is a^(m-2) mode m
                    return (power(a, m - 2, m));
                }
            }

            // To compute x^y under modulo m
            static long power(int x, int y, int m)
            {
                if (y == 0)
                    return 1;

                long p = power(x, y / 2, m) % m;
                p = (p * p) % m;

                if (y % 2 == 0)
                    return p;
                else
                    return (x * p) % m;
            }

            // Function to return gcd of a and b

        }
        class Student
        {
            int l;int r;
            public Student(int l, int r) {
                this.l = l;
                this.r = r;
            }
            // Constructor


            // Used to print student details in main()
            public String toString()
            {
                return this.l+" ";
            }
        }

        class Sortbyroll implements Comparator<Student>
        {
            // Used for sorting in ascending order of
            // roll number
            public int compare(Student a, Student b){
                if(a.l==b.l) return a.r-b.r;
                return a.l-b.l;  }
        } class Sortbyroll1 implements Comparator<Student>
        {
            // Used for sorting in ascending order of
            // roll number
            public int compare(Student a, Student b){
               if(a.r==b.r) return a.l-b.l;
                return a.r-b.r;
            }
        }