import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ]
        Scanner sc = new Scanner(System.in);
        Integer countResults = sc.nextInt();
        List<String> results = new ArrayList<String>();

        for(int i= 0; i <= countResults; i++){
           results.add(sc.nextLine());
        }

        int acCount = 0;
        int waCount = 0;
        int tleCount= 0;
        int reCount = 0;

        for(String result: results){
          if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          }
        }


        System.out.println("AC x " + acCount);
        System.out.println("WA x " + waCount);
        System.out.println("TLE x " + tleCount);
        System.out.println("RE x " + reCount);

	}

} import java.util.ArrayList; ArrayList java.util import java.util.List; List java.util import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ]
        Scanner sc = new Scanner(System.in);
        Integer countResults = sc.nextInt();
        List<String> results = new ArrayList<String>();

        for(int i= 0; i <= countResults; i++){
           results.add(sc.nextLine());
        }

        int acCount = 0;
        int waCount = 0;
        int tleCount= 0;
        int reCount = 0;

        for(String result: results){
          if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          }
        }


        System.out.println("AC x " + acCount);
        System.out.println("WA x " + waCount);
        System.out.println("TLE x " + tleCount);
        System.out.println("RE x " + reCount);

	}

} Main public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ]
        Scanner sc = new Scanner(System.in);
        Integer countResults = sc.nextInt();
        List<String> results = new ArrayList<String>();

        for(int i= 0; i <= countResults; i++){
           results.add(sc.nextLine());
        }

        int acCount = 0;
        int waCount = 0;
        int tleCount= 0;
        int reCount = 0;

        for(String result: results){
          if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          }
        }


        System.out.println("AC x " + acCount);
        System.out.println("WA x " + waCount);
        System.out.println("TLE x " + tleCount);
        System.out.println("RE x " + reCount);

	} main {
		// TODO 自動生成されたメソッド・スタブ]
        Scanner sc = new Scanner(System.in);
        Integer countResults = sc.nextInt();
        List<String> results = new ArrayList<String>();

        for(int i= 0; i <= countResults; i++){
           results.add(sc.nextLine());
        }

        int acCount = 0;
        int waCount = 0;
        int tleCount= 0;
        int reCount = 0;

        for(String result: results){
          if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          }
        }


        System.out.println("AC x " + acCount);
        System.out.println("WA x " + waCount);
        System.out.println("TLE x " + tleCount);
        System.out.println("RE x " + reCount);

	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) Integer countResults = sc.nextInt(); countResults sc.nextInt() sc.nextInt sc List<String> results = new ArrayList<String>(); results new ArrayList<String>() for(int i= 0; i <= countResults; i++){
           results.add(sc.nextLine());
        } int i= 0; int i= 0; i 0 i <= countResults i countResults i++ i++ i {
           results.add(sc.nextLine());
        } {
           results.add(sc.nextLine());
        } results.add(sc.nextLine()) results.add results sc.nextLine() sc.nextLine sc int acCount = 0; acCount 0 int waCount = 0; waCount 0 int tleCount= 0; tleCount 0 int reCount = 0; reCount 0 for(String result: results){
          if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          }
        } String result results {
          if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          }
        } {
          if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          }
        } if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          } result.equals("AC") result.equals result "AC" {
            acCount++;
          } acCount++ acCount if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          } result.equals("WA") result.equals result "WA" {
            waCount++;
          } waCount++ waCount if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          } result.equals("TLE") result.equals result "TLE" {
            tleCount++;
          } tleCount++ tleCount if(result.equals("RE")){
            reCount++;
          } result.equals("RE") result.equals result "RE" {
            reCount++;
          } reCount++ reCount System.out.println("AC x " + acCount) System.out.println System.out System System.out "AC x " + acCount "AC x " acCount System.out.println("WA x " + waCount) System.out.println System.out System System.out "WA x " + waCount "WA x " waCount System.out.println("TLE x " + tleCount) System.out.println System.out System System.out "TLE x " + tleCount "TLE x " tleCount System.out.println("RE x " + reCount) System.out.println System.out System System.out "RE x " + reCount "RE x " reCount String[] args args public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ]
        Scanner sc = new Scanner(System.in);
        Integer countResults = sc.nextInt();
        List<String> results = new ArrayList<String>();

        for(int i= 0; i <= countResults; i++){
           results.add(sc.nextLine());
        }

        int acCount = 0;
        int waCount = 0;
        int tleCount= 0;
        int reCount = 0;

        for(String result: results){
          if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          }
        }


        System.out.println("AC x " + acCount);
        System.out.println("WA x " + waCount);
        System.out.println("TLE x " + tleCount);
        System.out.println("RE x " + reCount);

	}

} public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ]
        Scanner sc = new Scanner(System.in);
        Integer countResults = sc.nextInt();
        List<String> results = new ArrayList<String>();

        for(int i= 0; i <= countResults; i++){
           results.add(sc.nextLine());
        }

        int acCount = 0;
        int waCount = 0;
        int tleCount= 0;
        int reCount = 0;

        for(String result: results){
          if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          }
        }


        System.out.println("AC x " + acCount);
        System.out.println("WA x " + waCount);
        System.out.println("TLE x " + tleCount);
        System.out.println("RE x " + reCount);

	}

} Main
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ]
        Scanner sc = new Scanner(System.in);
        Integer countResults = sc.nextInt();
        List<String> results = new ArrayList<String>();

        for(int i= 0; i <= countResults; i++){
           results.add(sc.nextLine());
        }

        int acCount = 0;
        int waCount = 0;
        int tleCount= 0;
        int reCount = 0;

        for(String result: results){
          if(result.equals("AC")){
            acCount++;
          }
          else if(result.equals("WA")){
            waCount++;
          }
          else if(result.equals("TLE")){
            tleCount++;
          }
          else if(result.equals("RE")){
            reCount++;
          }
        }


        System.out.println("AC x " + acCount);
        System.out.println("WA x " + waCount);
        System.out.println("TLE x " + tleCount);
        System.out.println("RE x " + reCount);

	}

}
