import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int cntAC=0;
        int cntWA=0;
        int cntTLE=0;
        int cntRE=0;
        while(n>0){
            n--;
            String s = sc.next();
            if(s.equals("AC")){
                cntAC++;
            }
            else if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            }
        }
        System.out.println(String.format("AC x %d",cntAC));
        System.out.println(String.format("WA x %d",cntWA));
        System.out.println(String.format("TLE x %d",cntTLE));
        System.out.println(String.format("RE x %d",cntRE));
    }
}
 import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int cntAC=0;
        int cntWA=0;
        int cntTLE=0;
        int cntRE=0;
        while(n>0){
            n--;
            String s = sc.next();
            if(s.equals("AC")){
                cntAC++;
            }
            else if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            }
        }
        System.out.println(String.format("AC x %d",cntAC));
        System.out.println(String.format("WA x %d",cntWA));
        System.out.println(String.format("TLE x %d",cntTLE));
        System.out.println(String.format("RE x %d",cntRE));
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int cntAC=0;
        int cntWA=0;
        int cntTLE=0;
        int cntRE=0;
        while(n>0){
            n--;
            String s = sc.next();
            if(s.equals("AC")){
                cntAC++;
            }
            else if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            }
        }
        System.out.println(String.format("AC x %d",cntAC));
        System.out.println(String.format("WA x %d",cntWA));
        System.out.println(String.format("TLE x %d",cntTLE));
        System.out.println(String.format("RE x %d",cntRE));
    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int cntAC=0;
        int cntWA=0;
        int cntTLE=0;
        int cntRE=0;
        while(n>0){
            n--;
            String s = sc.next();
            if(s.equals("AC")){
                cntAC++;
            }
            else if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            }
        }
        System.out.println(String.format("AC x %d",cntAC));
        System.out.println(String.format("WA x %d",cntWA));
        System.out.println(String.format("TLE x %d",cntTLE));
        System.out.println(String.format("RE x %d",cntRE));
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int cntAC=0; cntAC 0 int cntWA=0; cntWA 0 int cntTLE=0; cntTLE 0 int cntRE=0; cntRE 0 while(n>0){
            n--;
            String s = sc.next();
            if(s.equals("AC")){
                cntAC++;
            }
            else if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            }
        } n>0 n 0 {
            n--;
            String s = sc.next();
            if(s.equals("AC")){
                cntAC++;
            }
            else if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            }
        } n-- n String s = sc.next(); s sc.next() sc.next sc if(s.equals("AC")){
                cntAC++;
            }
            else if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            } s.equals("AC") s.equals s "AC" {
                cntAC++;
            } cntAC++ cntAC if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            } s.equals("WA") s.equals s "WA" {
                cntWA++;
            } cntWA++ cntWA if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            } s.equals("TLE") s.equals s "TLE" {
                cntTLE++;
            } cntTLE++ cntTLE if(s.equals("RE")){
                cntRE++;
            } s.equals("RE") s.equals s "RE" {
                cntRE++;
            } cntRE++ cntRE System.out.println(String.format("AC x %d",cntAC)) System.out.println System.out System System.out String.format("AC x %d",cntAC) String.format String "AC x %d" cntAC System.out.println(String.format("WA x %d",cntWA)) System.out.println System.out System System.out String.format("WA x %d",cntWA) String.format String "WA x %d" cntWA System.out.println(String.format("TLE x %d",cntTLE)) System.out.println System.out System System.out String.format("TLE x %d",cntTLE) String.format String "TLE x %d" cntTLE System.out.println(String.format("RE x %d",cntRE)) System.out.println System.out System System.out String.format("RE x %d",cntRE) String.format String "RE x %d" cntRE String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int cntAC=0;
        int cntWA=0;
        int cntTLE=0;
        int cntRE=0;
        while(n>0){
            n--;
            String s = sc.next();
            if(s.equals("AC")){
                cntAC++;
            }
            else if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            }
        }
        System.out.println(String.format("AC x %d",cntAC));
        System.out.println(String.format("WA x %d",cntWA));
        System.out.println(String.format("TLE x %d",cntTLE));
        System.out.println(String.format("RE x %d",cntRE));
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int cntAC=0;
        int cntWA=0;
        int cntTLE=0;
        int cntRE=0;
        while(n>0){
            n--;
            String s = sc.next();
            if(s.equals("AC")){
                cntAC++;
            }
            else if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            }
        }
        System.out.println(String.format("AC x %d",cntAC));
        System.out.println(String.format("WA x %d",cntWA));
        System.out.println(String.format("TLE x %d",cntTLE));
        System.out.println(String.format("RE x %d",cntRE));
    }
} Main
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int cntAC=0;
        int cntWA=0;
        int cntTLE=0;
        int cntRE=0;
        while(n>0){
            n--;
            String s = sc.next();
            if(s.equals("AC")){
                cntAC++;
            }
            else if(s.equals("WA")){
                cntWA++;
            }
            else if(s.equals("TLE")){
                cntTLE++;
            }
            else if(s.equals("RE")){
                cntRE++;
            }
        }
        System.out.println(String.format("AC x %d",cntAC));
        System.out.println(String.format("WA x %d",cntWA));
        System.out.println(String.format("TLE x %d",cntTLE));
        System.out.println(String.format("RE x %d",cntRE));
    }
}

