#include<stdio.h>
int main(void)
{
  int a,b;
  int cnt[4]={0};
  
   while((b=getchar())!=EDF){
     switch(b){
       case 'AT': cnt[0]++; break;
       case 'WA': cnt[1]++; break;
       case 'TLE': cnt[2]++; break;
       case 'RE': cnt[3]++; break;
     }
   }
  printf("AC×%d",cnt[0]);
  printf("WA×%d",cnt[1]);
  printf("TLE×%d",cnt[2]);
  printf("RE×%d",cnt[3]);
  
  return 0;
}
