import java.util.Scanner;

public class Main{

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		String[] array = new String[n];

		int account = 0;
		int wacount = 0;
		int tlecount = 0;
		int recount = 0;

		for(int i=0;i<array.length;i++) {
			array[i] = scan.next();
			if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			}
		}

		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.Scanner; Scanner java.util public class Main{

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		String[] array = new String[n];

		int account = 0;
		int wacount = 0;
		int tlecount = 0;
		int recount = 0;

		for(int i=0;i<array.length;i++) {
			array[i] = scan.next();
			if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			}
		}

		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 scan = new Scanner(System.in);
		int n = scan.nextInt();
		String[] array = new String[n];

		int account = 0;
		int wacount = 0;
		int tlecount = 0;
		int recount = 0;

		for(int i=0;i<array.length;i++) {
			array[i] = scan.next();
			if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			}
		}

		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 scan = new Scanner(System.in);
		int n = scan.nextInt();
		String[] array = new String[n];

		int account = 0;
		int wacount = 0;
		int tlecount = 0;
		int recount = 0;

		for(int i=0;i<array.length;i++) {
			array[i] = scan.next();
			if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			}
		}

		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 scan = new Scanner(System.in); scan new Scanner(System.in) int n = scan.nextInt(); n scan.nextInt() scan.nextInt scan String[] array = new String[n]; array new String[n] n int account = 0; account 0 int wacount = 0; wacount 0 int tlecount = 0; tlecount 0 int recount = 0; recount 0 for(int i=0;i<array.length;i++) {
			array[i] = scan.next();
			if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			}
		} int i=0; int i=0; i 0 i<array.length i array.length array array.length i++ i++ i {
			array[i] = scan.next();
			if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			}
		} {
			array[i] = scan.next();
			if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			}
		} array[i] = scan.next() array[i] array i scan.next() scan.next scan if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			} array[i].equals("AC") array[i].equals array[i] array i "AC" {
				account = account + 1;
			} account = account + 1 account account + 1 account 1 if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			} array[i].equals("WA") array[i].equals array[i] array i "WA" {
				wacount = wacount + 1;
			} wacount = wacount + 1 wacount wacount + 1 wacount 1 if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			} array[i].equals("TLE") array[i].equals array[i] array i "TLE" {
				tlecount = tlecount + 1;
			} tlecount = tlecount + 1 tlecount tlecount + 1 tlecount 1 if(array[i].equals("RE")) {
				recount = recount + 1;
			} array[i].equals("RE") array[i].equals array[i] array i "RE" {
				recount = recount + 1;
			} recount = recount + 1 recount recount + 1 recount 1 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 scan = new Scanner(System.in);
		int n = scan.nextInt();
		String[] array = new String[n];

		int account = 0;
		int wacount = 0;
		int tlecount = 0;
		int recount = 0;

		for(int i=0;i<array.length;i++) {
			array[i] = scan.next();
			if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			}
		}

		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 scan = new Scanner(System.in);
		int n = scan.nextInt();
		String[] array = new String[n];

		int account = 0;
		int wacount = 0;
		int tlecount = 0;
		int recount = 0;

		for(int i=0;i<array.length;i++) {
			array[i] = scan.next();
			if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			}
		}

		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.Scanner;

public class Main{

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner scan = new Scanner(System.in);
		int n = scan.nextInt();
		String[] array = new String[n];

		int account = 0;
		int wacount = 0;
		int tlecount = 0;
		int recount = 0;

		for(int i=0;i<array.length;i++) {
			array[i] = scan.next();
			if(array[i].equals("AC")) {
				account = account + 1;
			}else if(array[i].equals("WA")) {
				wacount = wacount + 1;
			}else if(array[i].equals("TLE")) {
				tlecount = tlecount + 1;
			}else if(array[i].equals("RE")) {
				recount = recount + 1;
			}
		}

		System.out.println("AC x "+account);
		System.out.println("WA x "+wacount);
		System.out.println("TLE x "+tlecount);
		System.out.println("RE x "+recount);

	}

}