#include <stdio.h>


int MAIN(){
  int n;
  int ac=0;
  int tle=0;
  int wa=0;
  int re=0;
  char s[n];
  scanf("%d", &n);
  for(int i=0;i<n;i++){
    scanf("%s", s[i]);
    switch (s[i]) {
      case "AC": ac++;
      case "WA": wa++;
      case "TLE": tle++;
      case "RE": re++;
    }
  }
  printf("AC × %d\n", ac);
  printf("WA × %d\n", wa);
  printf("TLE × %d\n", tle);
  printf("RE × %d\n", re);

  return 0;
}
