import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int N = Integer.parseInt(s.nextLine());
        String[] Sz = new String[N];
        for (int i = 0; i < N; i++){
            Sz[i] = s.nextLine();
        }
        HashMap<String,Integer> map = new HashMap<String,Integer>();
        for (int i = 0; i < N; i++){
            if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            }
        }
        if (map.get("AC") == null){
            System.out.println("AC x 0");
        } else {
            System.out.println("AC x "+map.get("AC"));
        }
        if (map.get("WA") == null){
            System.out.println("WA x 0");
        } else {
            System.out.println("WA x "+map.get("WA"));
        }
        if (map.get("TLE") == null){
            System.out.println("TLE x 0");
        } else {
            System.out.println("TLE x "+map.get("TLE"));
        }
        if (map.get("RE") == null){
            System.out.println("RE x 0");
        } else {
            System.out.println("RE x "+map.get("RE"));
        }
        
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int N = Integer.parseInt(s.nextLine());
        String[] Sz = new String[N];
        for (int i = 0; i < N; i++){
            Sz[i] = s.nextLine();
        }
        HashMap<String,Integer> map = new HashMap<String,Integer>();
        for (int i = 0; i < N; i++){
            if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            }
        }
        if (map.get("AC") == null){
            System.out.println("AC x 0");
        } else {
            System.out.println("AC x "+map.get("AC"));
        }
        if (map.get("WA") == null){
            System.out.println("WA x 0");
        } else {
            System.out.println("WA x "+map.get("WA"));
        }
        if (map.get("TLE") == null){
            System.out.println("TLE x 0");
        } else {
            System.out.println("TLE x "+map.get("TLE"));
        }
        if (map.get("RE") == null){
            System.out.println("RE x 0");
        } else {
            System.out.println("RE x "+map.get("RE"));
        }
        
    }
} Main public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int N = Integer.parseInt(s.nextLine());
        String[] Sz = new String[N];
        for (int i = 0; i < N; i++){
            Sz[i] = s.nextLine();
        }
        HashMap<String,Integer> map = new HashMap<String,Integer>();
        for (int i = 0; i < N; i++){
            if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            }
        }
        if (map.get("AC") == null){
            System.out.println("AC x 0");
        } else {
            System.out.println("AC x "+map.get("AC"));
        }
        if (map.get("WA") == null){
            System.out.println("WA x 0");
        } else {
            System.out.println("WA x "+map.get("WA"));
        }
        if (map.get("TLE") == null){
            System.out.println("TLE x 0");
        } else {
            System.out.println("TLE x "+map.get("TLE"));
        }
        if (map.get("RE") == null){
            System.out.println("RE x 0");
        } else {
            System.out.println("RE x "+map.get("RE"));
        }
        
    } main {
        Scanner s = new Scanner(System.in);
        int N = Integer.parseInt(s.nextLine());
        String[] Sz = new String[N];
        for (int i = 0; i < N; i++){
            Sz[i] = s.nextLine();
        }
        HashMap<String,Integer> map = new HashMap<String,Integer>();
        for (int i = 0; i < N; i++){
            if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            }
        }
        if (map.get("AC") == null){
            System.out.println("AC x 0");
        } else {
            System.out.println("AC x "+map.get("AC"));
        }
        if (map.get("WA") == null){
            System.out.println("WA x 0");
        } else {
            System.out.println("WA x "+map.get("WA"));
        }
        if (map.get("TLE") == null){
            System.out.println("TLE x 0");
        } else {
            System.out.println("TLE x "+map.get("TLE"));
        }
        if (map.get("RE") == null){
            System.out.println("RE x 0");
        } else {
            System.out.println("RE x "+map.get("RE"));
        }
        
    } Scanner s = new Scanner(System.in); s new Scanner(System.in) int N = Integer.parseInt(s.nextLine()); N Integer.parseInt(s.nextLine()) Integer.parseInt Integer s.nextLine() s.nextLine s String[] Sz = new String[N]; Sz new String[N] N for (int i = 0; i < N; i++){
            Sz[i] = s.nextLine();
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
            Sz[i] = s.nextLine();
        } {
            Sz[i] = s.nextLine();
        } Sz[i] = s.nextLine() Sz[i] Sz i s.nextLine() s.nextLine s HashMap<String,Integer> map = new HashMap<String,Integer>(); map new HashMap<String,Integer>() for (int i = 0; i < N; i++){
            if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            }
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
            if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            }
        } {
            if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            }
        } if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            } !map.keySet().contains(Sz[i]) map.keySet().contains(Sz[i]) map.keySet().contains map.keySet() map.keySet map Sz[i] Sz i {
                map.put(Sz[i],1);
            } map.put(Sz[i],1) map.put map Sz[i] Sz i 1 {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            } map.put(Sz[i],map.get(Sz[i]) + 1) map.put map Sz[i] Sz i map.get(Sz[i]) + 1 map.get(Sz[i]) map.get map Sz[i] Sz i 1 if (map.get("AC") == null){
            System.out.println("AC x 0");
        } else {
            System.out.println("AC x "+map.get("AC"));
        } map.get("AC") == null map.get("AC") map.get map "AC" null {
            System.out.println("AC x 0");
        } System.out.println("AC x 0") System.out.println System.out System System.out "AC x 0" {
            System.out.println("AC x "+map.get("AC"));
        } System.out.println("AC x "+map.get("AC")) System.out.println System.out System System.out "AC x "+map.get("AC") "AC x " map.get("AC") map.get map "AC" if (map.get("WA") == null){
            System.out.println("WA x 0");
        } else {
            System.out.println("WA x "+map.get("WA"));
        } map.get("WA") == null map.get("WA") map.get map "WA" null {
            System.out.println("WA x 0");
        } System.out.println("WA x 0") System.out.println System.out System System.out "WA x 0" {
            System.out.println("WA x "+map.get("WA"));
        } System.out.println("WA x "+map.get("WA")) System.out.println System.out System System.out "WA x "+map.get("WA") "WA x " map.get("WA") map.get map "WA" if (map.get("TLE") == null){
            System.out.println("TLE x 0");
        } else {
            System.out.println("TLE x "+map.get("TLE"));
        } map.get("TLE") == null map.get("TLE") map.get map "TLE" null {
            System.out.println("TLE x 0");
        } System.out.println("TLE x 0") System.out.println System.out System System.out "TLE x 0" {
            System.out.println("TLE x "+map.get("TLE"));
        } System.out.println("TLE x "+map.get("TLE")) System.out.println System.out System System.out "TLE x "+map.get("TLE") "TLE x " map.get("TLE") map.get map "TLE" if (map.get("RE") == null){
            System.out.println("RE x 0");
        } else {
            System.out.println("RE x "+map.get("RE"));
        } map.get("RE") == null map.get("RE") map.get map "RE" null {
            System.out.println("RE x 0");
        } System.out.println("RE x 0") System.out.println System.out System System.out "RE x 0" {
            System.out.println("RE x "+map.get("RE"));
        } System.out.println("RE x "+map.get("RE")) System.out.println System.out System System.out "RE x "+map.get("RE") "RE x " map.get("RE") map.get map "RE" String[] args args public class Main {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int N = Integer.parseInt(s.nextLine());
        String[] Sz = new String[N];
        for (int i = 0; i < N; i++){
            Sz[i] = s.nextLine();
        }
        HashMap<String,Integer> map = new HashMap<String,Integer>();
        for (int i = 0; i < N; i++){
            if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            }
        }
        if (map.get("AC") == null){
            System.out.println("AC x 0");
        } else {
            System.out.println("AC x "+map.get("AC"));
        }
        if (map.get("WA") == null){
            System.out.println("WA x 0");
        } else {
            System.out.println("WA x "+map.get("WA"));
        }
        if (map.get("TLE") == null){
            System.out.println("TLE x 0");
        } else {
            System.out.println("TLE x "+map.get("TLE"));
        }
        if (map.get("RE") == null){
            System.out.println("RE x 0");
        } else {
            System.out.println("RE x "+map.get("RE"));
        }
        
    }
} public class Main {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int N = Integer.parseInt(s.nextLine());
        String[] Sz = new String[N];
        for (int i = 0; i < N; i++){
            Sz[i] = s.nextLine();
        }
        HashMap<String,Integer> map = new HashMap<String,Integer>();
        for (int i = 0; i < N; i++){
            if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            }
        }
        if (map.get("AC") == null){
            System.out.println("AC x 0");
        } else {
            System.out.println("AC x "+map.get("AC"));
        }
        if (map.get("WA") == null){
            System.out.println("WA x 0");
        } else {
            System.out.println("WA x "+map.get("WA"));
        }
        if (map.get("TLE") == null){
            System.out.println("TLE x 0");
        } else {
            System.out.println("TLE x "+map.get("TLE"));
        }
        if (map.get("RE") == null){
            System.out.println("RE x 0");
        } else {
            System.out.println("RE x "+map.get("RE"));
        }
        
    }
} Main
import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int N = Integer.parseInt(s.nextLine());
        String[] Sz = new String[N];
        for (int i = 0; i < N; i++){
            Sz[i] = s.nextLine();
        }
        HashMap<String,Integer> map = new HashMap<String,Integer>();
        for (int i = 0; i < N; i++){
            if (!map.keySet().contains(Sz[i])){
                map.put(Sz[i],1);
            } else {
                map.put(Sz[i],map.get(Sz[i]) + 1);
            }
        }
        if (map.get("AC") == null){
            System.out.println("AC x 0");
        } else {
            System.out.println("AC x "+map.get("AC"));
        }
        if (map.get("WA") == null){
            System.out.println("WA x 0");
        } else {
            System.out.println("WA x "+map.get("WA"));
        }
        if (map.get("TLE") == null){
            System.out.println("TLE x 0");
        } else {
            System.out.println("TLE x "+map.get("TLE"));
        }
        if (map.get("RE") == null){
            System.out.println("RE x 0");
        } else {
            System.out.println("RE x "+map.get("RE"));
        }
        
    }
}