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 


// Working program with FastReader 
import java.io.BufferedReader; 
import java.io.IOException; 
import java.io.InputStreamReader; 
import java.util.*;
public class ll
{ 
    static class FastReader 
    { 
        BufferedReader br; 
        StringTokenizer st; 

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

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

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

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

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

        String nextLine() 
        { 
            String str = ""; 
            try
            { 
                str = br.readLine(); 
            } 
            catch (IOException e) 
            { 
                e.printStackTrace(); 
            } 
            return str; 
        } 
    } 

    static final int MAXN = 100001;
    // stores smallest prime factor for every number
    static int spf[] = new int[MAXN];
    // Calculating SPF (Smallest Prime Factor) for every
    // number till MAXN.
    // Time Complexity : O(nloglogn)
    static void sieve()
    {
        spf[1] = 1;
        for (int i=2; i<MAXN; i++)

        // marking smallest prime factor for every
        // number to be itself.
            spf[i] = i;

        // separately marking spf for every even
        // number as 2
        for (int i=4; i<MAXN; i+=2)
            spf[i] = 2;

        for (int i=3; i*i<MAXN; i++)
        {
            // checking if i is prime
            if (spf[i] == i)
            {
                // marking SPF for all numbers divisible by i
                for (int j=i*i; j<MAXN; j+=i)

                // marking spf[j] if it is not
                // previously marked
                    if (spf[j]==j)
                        spf[j] = i;
            }
        }
    }
    // A O(log n) function returning primefactorization
    // by dividing by smallest prime factor at every step
    static int getFactorization(int x)
    {
        int c=0;
        while (x != 1)
        {
            c++;
            x = x / spf[x];
        }
        return c;
    }

    /*
    static int LowerBound(int a[], int x) { // x is the target value or key
    int l=-1,r=a.length;
    while(l+1<r) {
    int m=(l+r)>>>1;
    if(a[m]>=x) r=m;
    else l=m;
    }
    return r;
    }

    static int UpperBound(int a[], int x) {// x is the key or target value
    int l=-1,r=a.length;
    while(l+1<r) {
    int m=(l+r)>>>1;
    if(a[m]<=x) l=m;
    else r=m;
    }
    return l+1;
    }
     */
    static int gcd(int a, int b)
    {
        if (a == 0)
            return b; 
        return gcd(b % a, a); 
    }

    // method to return LCM of two numbers
    static int lcm(int a, int b)
    {
        return (a / gcd(a, b)) * b;
    }

    public static int[] swap(int a[], int left, int right)
    {
        int temp = a[left];
        a[left] = a[right];
        a[right] = temp;
        return a;
    }

    public static int[] reverse(int a[], int left, int right)
    {
        // Reverse the sub-array
        while (left < right) {
            int temp = a[left];
            a[left++] = a[right];
            a[right--] = temp;
        }
        return a;
    }

    public static int[] findNextPermutation(int a[])
    {
        int last = a.length - 2;

        // find the longest non-increasing suffix
        // and find the pivot
        while (last >= 0) {
            if (a[last] < a[last + 1]) {
                break;
            }
            last--;
        }

        // If there is no increasing pair
        // there is no higher order permutation
        if (last < 0)
            return a;

        int nextGreater = a.length - 1;

        // Find the rightmost successor to the pivot
        for (int i = a.length - 1; i > last; i--) {
            if (a[i] > a[last]) {
                nextGreater = i;
                break;
            }
        }

        // Swap the successor and the pivot
        a = swap(a, nextGreater, last);

        // Reverse the suffix
        a = reverse(a, last + 1, a.length - 1);

        // Return true as the next_permutation is done
        return a;
    }

    static void sort(int[] a) {
        ArrayList<Integer> l = new ArrayList<>();
        for (int i : a)
            l.add(i);
        Collections.sort(l);
        for (int i = 0; i < a.length; i++)
            a[i] = l.get(i);
    }

    static double pow(double p,double tt)
    {
        double ii,q,r;
        q=1;
        r=p;
        while(tt>1)
        {
            for(ii=1;2*ii<=tt;ii*=2)
                p*=p;
            tt-=ii;
            q*=p;
            p=r;
        }
        if(tt==1)
            q*=r;
        return q;
    }

    static int factorial(int n)
    {
        return (n == 1 || n == 0) ? 1 : n * factorial(n - 1);
    }

    public static long primeFactors(long n)
    {
        long c=0l;
        long max=0l;
        long z=0l;
        //ArrayList <Integer> ll=new ArrayList<>();
        // Print the number of 2s that divide n
        while (n%2==0)
        {
            c++;
            n /= 2l;
            //ll.add(2);
        }
        if(c>max)
        {
            max=c;
            z=2;
        }
        // n must be odd at this point.  So we can
        // skip one element (Note i = i +2)
        for (int i = 3; i <= Math.sqrt(n); i+= 2)
        {
            // While i divides n, print i and divide n
            c=0;
            while (n%i == 0)
            {
                c++;
                n /= i;
                //ll.add(i);
            }
            if(c>max)
            {
                max=c;
                z=i;
            }
        }
        c=0;
        // This condition is to handle the case whien
        // n is a prime number greater than 2
        if (n > 2)
        {
            c++;
            //ll.add((int)n);
        }
        if(c>max)
        {
            max=c;
            z=n;
        }
        return z;
    }

    public static void pf(int n)
    {
        long c=0l;
        int j=0;
        //ArrayList <Integer> ll=new ArrayList<>();
        // Print the number of 2s that divide n
        int a[]=new int[2];
        if (n%2==0)
        {
            c++;
            n /= 2;
            a[j]=2;
            j++;
        }
        // n must be odd at this point.  So we can
        // skip one element (Note i = i +2)
        for (int i = 3; i <= Math.sqrt(n); i++)
        {
            // While i divides n, print i and divide n
            
            if (n%i == 0)
            {
                c++;
                n /= i;
                a[j]=i;
                j++;
                if(c==2)
                break;
            }
            
        }
        if(c==2 && n>=2)
            {
                if(n!=a[0] && n!=a[1])
                {
                    System.out.println("YES");
                    System.out.println(a[0]+" "+a[1]+" "+n);
                }
                else
                    System.out.println("NO");
            }
            else
            System.out.println("NO");
        
    }

    static void PrimeList(){
        int i,j;
        int sieve[]=new int[100001];
        for(i=2;i*i<=100000;i++)
        {
            if(sieve[i]==0)
            {
                for(j=i*i;j<=100000;j+=i)
                    sieve[j]=1;
            }
        }
        ArrayList<Integer> primes=new ArrayList<>();
        for(i=2;i<=100000;i++)
        {
            if(sieve[i]==0)
                primes.add(i);
        }
    }

    static int comp(int a[],int b[],int n)
    {
        int z=0;
        for(int i=0;i<n;i++)
        {
            if(a[i]!=b[i])
            {
                z=1;
                break;
            }
        }
        if(z==0)
            return 1;
        else
            return 0;
    }

    public static void main(String[] args) 
    {
        //try
        //{
        FastReader d=new FastReader();
        int t,i,j,k,l,r,n,q;
        int mod = (int) 1e9 + 7;

        int Inf=Integer.MAX_VALUE;
        int negInf=Integer.MIN_VALUE;
        t=d.nextInt();
        //t=1;
        String s;
        //char ch1,ch2,ch3,ch4;
        long ans,c,z;
        while(t-->0)
        {
            z=c=0l;
            ans=0l;
            n=d.nextInt();
            int m=d.nextInt();
            s=d.nextLine();
            int b[]=new int[m];
            for(i=0;i<m;i++)
            b[i]=d.nextInt();
            sort(b);
            int a[]=new int[26];
            j=0;
            for(i=0;i<m;i++)
            {
                while(j<b[i])
                {
                    a[s.charAt(j)-97]+=m-i;
                    j++;
                }
            }
            for(i=0;i<n;i++)
            a[s.charAt(i)-97]++;
            for(i=0;i<26;i++)
            System.out.print(a[i]+" ");
            System.out.println();
            //dont need extra d.nextLine()
        }
        /*
        }catch(Exception e)  {
        System.out.println(0);
        }*/
    }
}