import java.util.*;
 
public class Main{
  
  public static void main(String[] args){
    
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    
    if(n>=1 && n<=100000){
    String[] list = new String[n];
    for(int i=0; i < n; ++i){
      list[i] = sc.next();
    }
    
    int acCount = 0;
    int waCount = 0;
    int tleCount = 0;
    int reCount = 0;
    for(int i=0; i < n; ++i){
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.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);
    
    }else{
      System.out.println("入力条件に違反しています");
    }
  }  
    
} import java.util.*; util.* java public class Main{
  
  public static void main(String[] args){
    
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    
    if(n>=1 && n<=100000){
    String[] list = new String[n];
    for(int i=0; i < n; ++i){
      list[i] = sc.next();
    }
    
    int acCount = 0;
    int waCount = 0;
    int tleCount = 0;
    int reCount = 0;
    for(int i=0; i < n; ++i){
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.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);
    
    }else{
      System.out.println("入力条件に違反しています");
    }
  }  
    
} Main public static void main(String[] args){
    
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    
    if(n>=1 && n<=100000){
    String[] list = new String[n];
    for(int i=0; i < n; ++i){
      list[i] = sc.next();
    }
    
    int acCount = 0;
    int waCount = 0;
    int tleCount = 0;
    int reCount = 0;
    for(int i=0; i < n; ++i){
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.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);
    
    }else{
      System.out.println("入力条件に違反しています");
    }
  } main {
    
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    
    if(n>=1 && n<=100000){
    String[] list = new String[n];
    for(int i=0; i < n; ++i){
      list[i] = sc.next();
    }
    
    int acCount = 0;
    int waCount = 0;
    int tleCount = 0;
    int reCount = 0;
    for(int i=0; i < n; ++i){
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.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);
    
    }else{
      System.out.println("入力条件に違反しています");
    }
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc if(n>=1 && n<=100000){
    String[] list = new String[n];
    for(int i=0; i < n; ++i){
      list[i] = sc.next();
    }
    
    int acCount = 0;
    int waCount = 0;
    int tleCount = 0;
    int reCount = 0;
    for(int i=0; i < n; ++i){
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.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);
    
    }else{
      System.out.println("入力条件に違反しています");
    } n>=1 && n<=100000 n>=1 n 1 n<=100000 n 100000 {
    String[] list = new String[n];
    for(int i=0; i < n; ++i){
      list[i] = sc.next();
    }
    
    int acCount = 0;
    int waCount = 0;
    int tleCount = 0;
    int reCount = 0;
    for(int i=0; i < n; ++i){
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.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);
    
    } String[] list = new String[n]; list new String[n] n for(int i=0; i < n; ++i){
      list[i] = sc.next();
    } int i=0; int i=0; i 0 i < n i n ++i ++i i {
      list[i] = sc.next();
    } {
      list[i] = sc.next();
    } list[i] = sc.next() list[i] list i sc.next() sc.next sc 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 < n; ++i){
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.equals("RE")){
        reCount++;
      }
      
    } int i=0; int i=0; i 0 i < n i n ++i ++i i {
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.equals("RE")){
        reCount++;
      }
      
    } {
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.equals("RE")){
        reCount++;
      }
      
    } String str = list[i]; str list[i] list i if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.equals("RE")){
        reCount++;
      } str.equals("AC") str.equals str "AC" {
        acCount++;
      } acCount++ acCount if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.equals("RE")){
        reCount++;
      } str.equals("WA") str.equals str "WA" {
        waCount++;
      } waCount++ waCount if(str.equals("TLE")){
        tleCount++;
      }else if(str.equals("RE")){
        reCount++;
      } str.equals("TLE") str.equals str "TLE" {
        tleCount++;
      } tleCount++ tleCount if(str.equals("RE")){
        reCount++;
      } str.equals("RE") str.equals str "RE" {
        reCount++;
      } reCount++ reCount System.out.println("AC" + " " + "x" + " " + acCount) System.out.println System.out System System.out "AC" + " " + "x" + " " + acCount " " "x" "AC" + " " + "x" + " " + acCount "AC" " " "x" " " acCount System.out.println("WA" + " " + "x" + " " + waCount) System.out.println System.out System System.out "WA" + " " + "x" + " " + waCount " " "x" "WA" + " " + "x" + " " + waCount "WA" " " "x" " " waCount System.out.println("TLE" + " " + "x" + " " + tleCount) System.out.println System.out System System.out "TLE" + " " + "x" + " " + tleCount " " "x" "TLE" + " " + "x" + " " + tleCount "TLE" " " "x" " " tleCount System.out.println("RE" + " " + "x" + " " + reCount) System.out.println System.out System System.out "RE" + " " + "x" + " " + reCount " " "x" "RE" + " " + "x" + " " + reCount "RE" " " "x" " " reCount {
      System.out.println("入力条件に違反しています");
    } System.out.println("入力条件に違反しています") System.out.println System.out System System.out "入力条件に違反しています" String[] args args public class Main{
  
  public static void main(String[] args){
    
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    
    if(n>=1 && n<=100000){
    String[] list = new String[n];
    for(int i=0; i < n; ++i){
      list[i] = sc.next();
    }
    
    int acCount = 0;
    int waCount = 0;
    int tleCount = 0;
    int reCount = 0;
    for(int i=0; i < n; ++i){
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.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);
    
    }else{
      System.out.println("入力条件に違反しています");
    }
  }  
    
} public class Main{
  
  public static void main(String[] args){
    
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    
    if(n>=1 && n<=100000){
    String[] list = new String[n];
    for(int i=0; i < n; ++i){
      list[i] = sc.next();
    }
    
    int acCount = 0;
    int waCount = 0;
    int tleCount = 0;
    int reCount = 0;
    for(int i=0; i < n; ++i){
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.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);
    
    }else{
      System.out.println("入力条件に違反しています");
    }
  }  
    
} Main
import java.util.*;
 
public class Main{
  
  public static void main(String[] args){
    
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    
    if(n>=1 && n<=100000){
    String[] list = new String[n];
    for(int i=0; i < n; ++i){
      list[i] = sc.next();
    }
    
    int acCount = 0;
    int waCount = 0;
    int tleCount = 0;
    int reCount = 0;
    for(int i=0; i < n; ++i){
      String str = list[i];
      
      if(str.equals("AC")){
        acCount++;
      }else if(str.equals("WA")){
        waCount++;
      }else if(str.equals("TLE")){
        tleCount++;
      }else if(str.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);
    
    }else{
      System.out.println("入力条件に違反しています");
    }
  }  
    
}