Problem:
 Score : 200 points    Problem Statement Takahashi is participating in a programming contest called AXC002, and he has just submitted his code to Problem A.  The problem has N test cases.  For each test case i ( 1\leq i \leq N ), you are given a string S_i representing the verdict for that test case. Find the numbers of test cases for which the verdict is AC , WA , TLE , and RE , respectively.  See the Output section for the output format.      Constraints  1 \leq N \leq 10^5  S_i is AC , WA , TLE , or RE .         Input Input is given from Standard Input in the following format:  N  S_1  \vdots  S_N       Output Let C_0 , C_1 , C_2 , and C_3 be the numbers of test cases for which the verdict is AC , WA , TLE , and RE , respectively. Print the following:  AC x C_0 WA x C_1 TLE x C_2 RE x C_3         Sample Input 1 6
AC
TLE
AC
AC
WA
TLE      Sample Output 1 AC x 3
WA x 1
TLE x 2
RE x 0  We have 3 , 1 , 2 , and 0 test case(s) for which the verdict is AC , WA , TLE , and RE , respectively.       Sample Input 2 10
AC
AC
AC
AC
AC
AC
AC
AC
AC
AC      Sample Output 2 AC x 10
WA x 0
TLE x 0
RE x 0

Solution (Python):
n = int(input())

ac = 0
wa = 0
tle = 0
re = 0

for _ in range(n):
    i = input()

    if i == "AC":
        ac += 1
    if i == "WA":
        wa += 1
    if i == "TLE":
        tle += 1
    if i == "RE":
        re += 1

print("AC x {}".format(ac))
print("WA x {}".format(wa))
print("TLE x {}".format(tle))
print("RE x {}".format(re))

Solution (Python):
n = int(input())
s = [input() for _ in range(n)]
for key in ('AC', 'WA', 'TLE', 'RE'):
    print('{} x {}'.format(key, s.count(key)))

Solution (Python):
len = int(input())

dict = {}

for i in range(len):
    result = input()

    if result in dict:
        dict[result] += 1
    else:
        dict[result] = 1

keys = ['AC', 'WA', 'TLE', 'RE']
for k in keys:
    cnt = 0
    if k in dict:
        cnt = dict[k]
    print("{0} x {1}".format(k, cnt))

Solution (Python):
N = int(input())

counter = {'AC': 0, 'WA': 0, 'TLE': 0, 'RE': 0}

for i in range(N):
    res = input()
    counter[res] += 1

for k in counter:
    print("{} x {}".format(k, counter[k]))

Solution (Python):
N = int(input())
s = [input() for i in range(N)]
for v in ['AC', 'WA', 'TLE', 'RE']:
  print('{0} x {1}'.format(v, s.count(v)))

Solution (Python):
n = int(input())
j = [0]*4
s = []

for i in range(n):
    si = input()
    s.append(si)

for i in range(n):
    if s[i] == "AC":
        j[0] += 1
    elif s[i] == "WA":
        j[1] += 1
    elif s[i] == "TLE":
        j[2] += 1
    else :
        j[3] += 1

print("AC x "+str(j[0]))
print("WA x "+str(j[1]))
print("TLE x "+str(j[2]))
print("RE x "+str(j[3]))

Solution (Python):
n = int(input())
s = [input() for _ in range(n)]

import collections
c = collections.Counter(s)

for i in ["AC","WA","TLE","RE"]:
    print(i,"x",c[i])

Solution (Python):
from collections import Counter
n = int(input())
count = Counter()
for _ in range(n):
    verdict = input()
    count[verdict] += 1
print("AC x", count["AC"])
print("WA x", count["WA"])
print("TLE x", count["TLE"])
print("RE x", count["RE"])

Solution (Python):
n = int(input())
ls = []
for _ in range(n):
    tmp = input()
    ls.append(tmp)

print(f"AC x {ls.count('AC')}")
print(f"WA x {ls.count('WA')}")
print(f"TLE x {ls.count('TLE')}")
print(f"RE x {ls.count('RE')}")

Solution (Python):


N = int(input())
D = {
    "AC": 0,
    "WA": 0,
    "TLE": 0,
    "RE": 0
}

for _ in range(N):
    s = input()
    D[s] += 1

for status in ["AC", "WA", "TLE", "RE"]:
    print("%s x %d" % (status, D[status]))

Solution (Python):
n = int(input())
l = ['AC','WA','TLE','RE']
c = [input() for _ in range(n)]
for k in l:print(k,'x',c.count(k))

Solution (Python):
n = int(input())
l = {'AC':0, 'WA':0, 'TLE':0, 'RE':0}
for _ in range(n):l[input()] += 1
for k in l.keys():print(k+' x '+str(l[k]))

Solution (Python):
n=int(input())
d=dict()
a=["AC","WA","TLE","RE"]
for x in a:
	d[x]=0
for _ in range(n):
	d[input()]+=1
for x in a:
	print(x + " x " + str(d[x]))

Solution (Python):
n = int(input())

AC, WA, TLE, RE = 0, 0, 0, 0

for _ in range(n):
    s = input()

    if s == 'AC':
        AC += 1
    elif s == 'WA':
        WA += 1
    elif s == 'TLE':
        TLE += 1
    else:
        RE += 1

print(f'AC x {AC}')
print(f'WA x {WA}')
print(f'TLE x {TLE}')
print(f'RE x {RE}')

Solution (Python):
N = int(input())
cnt = [0]*4
for i in range(N):
  x = input()
  if x == 'AC':
    cnt[0]+=1
  elif x == 'WA':
    cnt[1]+=1
  elif x == 'TLE':
    cnt[2]+=1
  else:
    cnt[3]+=1
print('AC x {}'.format(cnt[0]))
print('WA x {}'.format(cnt[1]))
print('TLE x {}'.format(cnt[2]))
print('RE x {}'.format(cnt[3]))

Solution (Python):


from collections import Counter


def main():
    N = int(input())
    S = [input() for _ in range(N)]

    aar = ["AC", "WA", "TLE", "RE"]

    cnt = Counter(S)

    for value in aar:
        if value in cnt.keys():
            print(value, cnt[value], sep=" x ")
        else:
            print(value, 0, sep=" x ")


if __name__ == "__main__":
    main()

Solution (Python):
N=int(input())
S=[input() for i in range(N)]
print('AC','x',S.count('AC'))
print('WA','x',S.count('WA'))
print('TLE','x',S.count('TLE'))
print('RE','x',S.count('RE'))

Solution (Python):
n = int(input())
ac,wa,tle,re = 0,0,0,0
for i in range(n):
    case = input()
    if case == 'AC':
        ac += 1
    elif case == 'WA':
        wa += 1
    elif case == 'TLE':
        tle += 1
    elif case == 'RE':
        re += 1

print('AC x ' + str(ac))
print('WA x ' + str(wa))
print('TLE x ' + str(tle))
print('RE x ' + str(re))

Solution (Python):
N = int(input())
Si = []
for i in range(N):
	Si.append(input())
print(f"AC x {Si.count('AC')}")
print(f"WA x {Si.count('WA')}")
print(f"TLE x {Si.count('TLE')}")
print(f"RE x {Si.count('RE')}")

Solution (Python):
n = int(input())
c = [0] * 4
str = ['AC', 'WA', 'TLE', 'RE']
for _ in range(n):
    s = input()
    if s in str:
        i = str.index(s)
        c[i] += 1
for s, ct in zip(str, c):
    print('{} x {}'.format(s, ct))

Solution (Python):
N = int(input())
hist = {'AC': 0, 'WA': 0, 'TLE': 0, 'RE': 0 }
for i in range(N):
  tc = input()
  hist[tc] += 1

for k in ['AC', 'WA', 'TLE', 'RE']:
  print(f'{k} x {hist[k]}', flush=True)

Solution (Python):
N=int(input())
cnt=0
S=[]
while cnt < N:
    S.append(input())
    cnt += 1
print(f'AC x {S.count("AC")}')
print(f'WA x {S.count("WA")}')
print(f'TLE x {S.count("TLE")}')
print(f'RE x {S.count("RE")}')

Solution (Python):
a = int(input())
b = [input() for i in range(a)]
c = ["AC", "WA", "TLE", "RE"]
for d in c:
  print(f"{d} x {b.count(d)}")

Solution (Python):
ac = 0
wa = 0
tle = 0
re = 0

n = int(input())

for _ in range(n):
    result = input()
    if(result == "AC"):
        ac += 1
    if(result == "WA"):
        wa += 1
    if(result == "TLE"):
        tle += 1
    if(result == "RE"):
        re += 1

print("AC x {}".format(ac))
print("WA x {}".format(wa))
print("TLE x {}".format(tle))
print("RE x {}".format(re))

Solution (Python):
l=[0]*4
for i in range(int(input())):
  s=input()
  if s=='AC':
    l[0]+=1
  elif s=='WA':
    l[1]+=1
  elif s=='RE':
    l[3]+=1
  else:
    l[2]+=1
print(f'AC x {l[0]}',f'WA x {l[1]}',f'TLE x {l[2]}',f'RE x {l[3]}')

Solution (Python):
from collections import defaultdict as dd
from collections import deque
import bisect
import heapq

def ri():
    return int(input())

def rl():
    return list(map(int, input().split()))


def solve():
    n = ri()
    d = dd(int)
    for i in range(n):
        d[input()] += 1

    for c in ["AC", "WA", "TLE", "RE"]:
        print (c, "x", d[c])






mode = 's'

if mode == 'T':
    t = ri()
    for i in range(t):
        solve()
else:
    solve()

Solution (Python):
n = int(input());
ac=wa=tle=re = 0;
for i in range(n) :
    s = input();
    if s == 'AC' :
        ac += 1;
    elif s == 'WA' :
        wa += 1;
    elif s == 'TLE' :
        tle += 1;
    else :
        re += 1;

print("AC x ",ac);
print("WA x ",wa);
print("TLE x ",tle);
print("RE x ",re);

Solution (Python):
n = int(input())
s = {"AC": 0, "WA": 0, "TLE": 0, "RE": 0}
for i in range(n):
    s[input()] += 1

for k, v in s.items():
    print(f"{k} x {v}")

Solution (Python):
















production = True

import sys, math, collections

def input(input_format = 0, multi = 0):

    if multi > 0: return [input(input_format) for i in range(multi)]
    else:
        next_line = sys.stdin.readline()[:-1]

        if input_format >= 10:
            use_list = False
            input_format = int(str(input_format)[-1])
        else: use_list = True

        if input_format == 0: formatted_input = [next_line]
        elif input_format == 1: formatted_input = list(map(int, next_line.split()))
        elif input_format == 2: formatted_input = list(map(float, next_line.split()))
        elif input_format == 3: formatted_input = list(next_line)
        elif input_format == 4: formatted_input = list(map(int, list(next_line)))
        elif input_format == 5: formatted_input = next_line.split()
        else: formatted_input = [next_line]

        return formatted_input if use_list else formatted_input[0]

def out(output_line, output_format = 0, newline = True):

    formatted_output = ""

    if output_format == 0: formatted_output = str(output_line)
    elif output_format == 1: formatted_output = " ".join(map(str, output_line))
    elif output_format == 2: formatted_output = "\n".join(map(str, output_line))

    print(formatted_output, end = "\n" if newline else "")

def log(*args):
    if not production:
        print("$$$", end = "")
        print(*args)

enu = enumerate

ter = lambda a, b, c: b if a else c

def mapl(iterable, format = 0):
    
    if format == 0: return list(map(int, iterable))
    elif format == 1: return list(map(str, iterable))
    elif format == 2: return list(map(list, iterable))





def solve():

    n = input(11)
    g = input(0, n)

    a = t = w = r = 0

    for i in g:
        i = i[0]
        if i == "AC":
            a += 1
        elif i == "TLE":
            t += 1
        elif i == "WA":
            w += 1
        elif i == "RE":
            r += 1

    out(f"AC x {a}")
    out(f"WA x {w}")
    out(f"TLE x {t}")
    out(f"RE x {r}")

    return



solve()

Solution (Python):
from collections import Counter
n = int(input())
l = [input() for i in range(n)]
c = Counter(l)
for s in ["AC","WA","TLE","RE"]:
    if c[s]:
        print(s,"x",c[s])
    else:
        print(s,"x",0)

Solution (Python):
N = int(input())

lists = [0]*4
for i in range(N):
  s = input()
  if "AC"==s:
    lists[0] += 1
  elif "WA"==s:
    lists[1] += 1
  elif "TLE"==s:
    lists[2] += 1
  else:
    lists[3] += 1

print("AC x {}".format(lists[0]))
print("WA x {}".format(lists[1]))
print("TLE x {}".format(lists[2]))
print("RE x {}".format(lists[3]))

Solution (Python):
n = int(input())
l = {'AC':0, 'WA':0, 'TLE':0, 'RE':0}
for _ in range(n):
  b = input()
  l[b] += 1
for k in l.keys():
  print(str(k)+' x '+str(l[k]))

Solution (Python):
d = {'AC':0, 'WA':0, 'TLE':0, 'RE':0}
for i in range(int(input())): d[input()]+=1
for i in d: print(i+' x', d[i])

Solution (Python):
from collections import Counter 
N = int(input())
words = []
for i in range(N):
    S = input()
    words.append(S)
cnt = Counter(words)
for x in ['AC', 'WA', 'TLE', 'RE']:
    n = cnt[x]
    print('{} x {}'.format(x, n))

Solution (Python):
n = int(input())
dicts = {}
for i in range(n):
    tempstr = input()
    if tempstr not in dicts:
        dicts[tempstr] = 1 
    else:
        dicts[tempstr] += 1 
if "AC" not in dicts:
    dicts["AC"] = 0 
if "WA" not in dicts:
    dicts["WA"] = 0 
if "TLE" not in dicts:
    dicts["TLE"] = 0 
if "RE" not in dicts:
    dicts["RE"] = 0 
print("AC x " + str(dicts["AC"]))
print("WA x " + str(dicts["WA"]))
print("TLE x " + str(dicts["TLE"]))
print("RE x " + str(dicts["RE"]))

Solution (Python):
N=int(input())
S = []
for _ in range(N):
    S.append(input())
a=0
b=0
c=0
d=0
for i in S:
  if i=='AC':
    a+=1
  elif i=='WA':
    b+=1
  elif i=='TLE':
    c+=1
  else:
    d+=1
print('AC x '+str(a))
print('WA x '+str(b))
print('TLE x '+str(c))
print('RE x '+str(d))

Solution (Python):
from collections import Counter

counter = Counter()
n = int(input())

for _ in range(n):
  s = input()
  counter[s] += 1

for item in ["AC", "WA", "TLE", "RE"]:
  print("{0} x {1}".format(item, counter[item]))

Solution (Python):
from collections import Counter as C
n = int(input())
l = [input() for _ in range(n)]
c = C(l)
for k in ['AC', 'WA', 'TLE', 'RE']:
  if k not in c:
    print('{} x 0'.format(k))
  else:
    print('{} x {}'.format(k, c[k]))

Solution (Python):
import collections
N = int(input())
S=[]
for i in range(N):
    S.append(input())
c = collections.Counter(S)
print('AC x {}'.format(c['AC']))
print('WA x {}'.format(c['WA']))
print('TLE x {}'.format(c['TLE']))
print('RE x {}'.format(c['RE']))

Solution (Python):
def B():
    N = int(input())
    count = {'AC':0, 'WA':0, 'TLE':0, 'RE':0}
    for _ in range(N):
        count[input()] += 1
    for k in count:
        print(k, 'x', count[k])
B()

Solution (Python):
N = int(input())

S = []
for _ in range(N):
  S.append(input())

print('{} {} {}'.format('AC','x',S.count('AC')))
print('{} {} {}'.format('WA','x',S.count('WA')))
print('{} {} {}'.format('TLE','x',S.count('TLE')))
print('{} {} {}'.format('RE','x',S.count('RE')))

Solution (Python):
c0 = c1 = c2 = c3 = 0

N = int(input())
for i in range(N):
    s = input()
    if s == 'AC':
        c0 += 1
    elif s == 'WA':
        c1 += 1
    elif s == 'TLE':
        c2 += 1
    else:
        c3 += 1
tmp = ['AC', 'WA', 'TLE', 'RE']
tmp2 = [c0, c1, c2, c3]        

for i in range(4):
    print(tmp[i] + ' ' + 'x' + ' ' + str(tmp2[i]))

Solution (Python):
N = int(input())
dic = {}
dic['AC'] = 0
dic['WA'] = 0
dic['TLE'] = 0
dic['RE'] = 0
for i in range(N):
  s = input().strip()
  dic[s] += 1
print("AC x ",end = '')
print(dic['AC'])
print("WA x ",end = '')
print(dic['WA'])
print("TLE x ",end = '')
print(dic['TLE'])
print("RE x ",end = '')
print(dic['RE'])

Solution (Python):

n=int(input())
s=[]
for i in range(n):
 s.append(input())
print('AC x',s.count('AC'))
print('WA x',s.count('WA'))
print('TLE x',s.count('TLE'))
print('RE x',s.count('RE'))

Solution (Python):
n = int(input())

ans = {'AC':0,'WA':0,'TLE':0,'RE':0}

for _ in range(n):
    s = input()
    ans[s] += 1

for k,v in ans.items():
    print(k, ' x ',v)

Solution (Python):
import collections

N=int(input())
words=[input() for _ in range(N)]

counter = collections.Counter(words)
for x in ['AC', 'WA', 'TLE', 'RE']:
  n = counter[x]
  print('{} x {}'.format(x,n))

Solution (Python):
N = int(input())
C0 = 0
C1 = 0
C2 = 0
C3 = 0


for i in range(N):
    C = input()

    if C == 'AC':
        C0 += 1
    elif C == 'WA':
        C1 += 1
    elif C == 'TLE':
        C2 += 1
    elif C == 'RE':
        C3 += 1

print('AC x ' + str(C0))
print('WA x ' + str(C1))
print('TLE x ' + str(C2))
print('RE x ' + str(C3))

Solution (Python):
from collections import Counter as ct

n = int(input())
s = ct([input() for _ in range(n)])
print("AC x " + str(s["AC"]))
print("WA x " + str(s["WA"]))
print("TLE x " + str(s["TLE"]))
print("RE x " + str(s["RE"]))

Solution (Python):
L = []
for i in range(int(input())):
  L.append(input())
for j in ['AC','WA','TLE','RE']:
  print(j,'x',L.count(j))

Solution (Python):
N = int(input())
ans = [0]*4
resList = ["AC","WA","TLE","RE"]
res = ""
for i in range(N):
  res = str(input())
  for j in range(4):
    if res == resList[j]:
      ans[j] += 1
for i in range(4):
  print(resList[i] + " x " + str(ans[i]))

Solution (Python):
n = int(input())
v = [0] * 4
for i in range(n):
    s = input()
    if s == 'AC': v[0] += 1
    elif s == 'WA': v[1] += 1
    elif s == 'TLE': v[2] += 1
    else: v[3] += 1
print('AC x ',v[0])
print('WA x ',v[1])
print('TLE x ',v[2])
print('RE x ',v[3])

Solution (Python):
N = int(input())
S = [input() for _ in range(N)]
V = ['AC', 'WA', 'TLE', 'RE']
for v in V:
    print('{0} x {1}'.format(v, S.count(v)))

Solution (Python):
n = int(input())
s = [input() for i in range(n)]
print("AC x " + str(s.count("AC")))
print("WA x " + str(s.count("WA")))
print("TLE x " + str(s.count("TLE")))
print("RE x " + str(s.count("RE")))

Solution (Python):
n = int(input())

results = {
	'AC': 0,
	'WA': 0,
	'TLE': 0,
	'RE': 0,
}

for _ in range(n):
  r = input()
  results[r] += 1

for r in ('AC', 'WA', 'TLE', 'RE'):
  print('{} x {}'.format(r, results[r]))

Solution (Python):
n = int(input())
s = [input() for i in range(n)]
for i in ['AC', 'WA', 'TLE', 'RE']:
    print(i, 'x',  s.count(i))

Solution (Python):
from collections import Counter

n = int(input())
cnt = Counter([input() for _ in range(n)])
  
for x in ['AC', 'WA', 'TLE', 'RE']:
  print("{} x {}".format(x, cnt[x]))

Solution (Python):
n = int(input())
d = {}

for _ in range(n):
  a = input()
  d[a] = d.get(a, 0) + 1
  
for x in ['AC', 'WA', 'TLE', 'RE']:
  print(x + ' x ' + str(d.get(x, 0)))

Solution (Python):
from collections import defaultdict
n = int(input())
cnt = defaultdict(int)
for _ in range(n):
    s = input()
    cnt[s] += 1

labels = ['AC', 'WA', 'TLE', 'RE']
for label in labels:
    print(label, 'x', cnt[label])

Solution (Python):
import sys

input = sys.stdin.readline


def int_array():
    return list(map(int, input().strip().split()))


def str_array():
    return input().strip().split()


def lower_letters():
    lowercase = [chr(i) for i in range(97, 97+26)]
    return lowercase

def how_frequent(lis):
	last = None
	count = []
	each = 1
	for i in range(len(lis)):
		if last != None:
			last = lis[i-1]
		if last == lis[i]:
			each += 1
		else:
			count.append(each)
			each = 0
		last = lis[i]
	return max(count)


def upper_letters():
    uppercase = [chr(i) for i in range(65, 65+26)]
    return uppercase




n = int(input())
ac,tle,re,wa= 0,0,0,0
for i in range(n):
	s = input().strip()
	if s == "AC":
		ac+=1
	elif s == "TLE":
		tle +=1
	elif s == "RE":
		re+=1
	else:
		wa+=1

print(f"AC x {ac}\nWA x {wa}\nTLE x {tle}\nRE x {re}\n")

Solution (Python):

import sys
input = sys.stdin.readline


def ceil(x):
    if x != int(x):
        x = int(x) + 1;
    return x;
    

def swaparr(arr, a,b):
    temp = arr[a];
    arr[a] = arr[b];
    arr[b] = temp


def gcd(a,b):
    if b == 0:
        return a
    return gcd(b, a % b);


def nCr(n, k): 
    if(k > n - k): 
        k = n - k 
    res = 1
    for i in range(k): 
        res = res * (n - i) 
        res = res / (i + 1) 
    return int(res) 


def upper_bound(a, x, lo=0, hi = None):
    if hi == None:
        hi = len(a);
    while lo < hi:
        mid = (lo+hi)//2
        if a[mid] < x:
            lo = mid+1
        else:
            hi = mid
    return lo


def primefs(n):
    
    primes = {}
    while(n%2 == 0 and n > 0):
        primes[2] = primes.get(2, 0) + 1
        n = n//2
    for i in range(3, int(n**0.5)+2, 2):
        while(n%i == 0 and n > 0):
            primes[i] = primes.get(i, 0) + 1
            n = n//i
    if n > 2:
        primes[n] = primes.get(n, 0) + 1
    
    
    return primes


def power(x, y, p): 
    res = 1
    x = x % p  
    if (x == 0) : 
        return 0
    while (y > 0) : 
        if ((y & 1) == 1) : 
            res = (res * x) % p 
        y = y >> 1      
        x = (x * x) % p 
    return res 


def swap(a,b):
    temp = a
    a = b
    b = temp
    return a,b









def find(x, link):
    p = x;
    while( p != link[p]):
        p = link[p];
    
    while( x != p):
        nex = link[x];
        link[x] = p;
        x = nex;
    return p;




def union(x, y, link, size):
    x = find(x, link)
    y = find(y, link)
    if size[x] < size[y]:
        x,y = swap(x,y)
    if x != y:
        size[x] += size[y]
        link[y] = x


def sieve(n): 
    prime = [True for i in range(n+1)] 
    p = 2
    while (p * p <= n): 
        if (prime[p] == True): 
            for i in range(p * p, n+1, p):
                prime[i] = False
        p += 1
    return prime


MAXN = int(1e5 + 5)
def spf_sieve():
    spf[1] = 1;
    for i in range(2, MAXN):
        spf[i] = i;
    for i in range(4, MAXN, 2):
        spf[i] = 2;
    for i in range(3, ceil(MAXN ** 0.5), 2):
        if spf[i] == i:
            for j in range(i*i, MAXN, i):
                if spf[j] == j:
                    spf[j] = i;
    




def factoriazation(x):
    ret = {};
    while x != 1:
        ret[spf[x]] = ret.get(spf[x], 0) + 1;
        x = x//spf[x]
    return ret
    
    


def int_array():
    return list(map(int, input().strip().split()))

def str_array():
    return input().strip().split();


MOD = int(1e9)+7;
CMOD = 998244353;
INF = float('inf'); NINF = -float('inf');



n = int(input()); 
dick = {'AC' : 0, 'WA' : 0, 'TLE' : 0, 'RE' : 0};
for _ in range(n):
    dick[input().strip()] += 1;
for i in dick:
    print(i,' x ',dick[i]);

Solution (Python):
n = int(input())
AC= 0
WA= 0
TLE = 0
RE = 0

for x in range(n):
    s = input()
    if s == "AC":
        AC = AC +1
    elif s == "WA":
        WA += 1
    elif s == "TLE":
        TLE += 1
    elif s == "RE":
        RE +=1
print("AC x", AC)
print("WA x", WA)
print("TLE x", TLE)
print("RE x", RE)

Solution (Python):
ac = wa = tle = re = 0

for i in range(int(input())):
    S = input()
    if S == 'AC':
        ac += 1
    elif S == 'WA':
        wa += 1
    elif S == 'TLE':
        tle += 1
    else:
        re += 1
print('AC x {}'.format(ac))
print('WA x {}'.format(wa))
print('TLE x {}'.format(tle))
print('RE x {}'.format(re))

Solution (Python):
import sys 
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
N = int(readline())
S = read().decode().rstrip().split()
for s in ['AC','WA','TLE','RE']:
    print("{0} x {1}".format(s,S.count(s)))

Solution (Python):
c=open(0).read().count
for s in'AC','WA','TLE','RE':print(s,'x',c(s))

Solution (Python):
n = int(input())
s = []
for i in range(n):
  s.append(input())

judge = {'AC':0,'WA':0, 'TLE':0, 'RE':0}

for s1 in s:
  if s1 == 'AC':
    judge['AC']+=1
  elif s1 == 'WA':
    judge['WA']+=1
  elif s1 == 'TLE':
    judge['TLE']+=1
  else:
    judge['RE']+=1
print("AC x "f"{judge['AC']}")
print("WA x "f"{judge['WA']}")
print("TLE x "f"{judge['TLE']}")
print("RE x "f"{judge['RE']}")

Solution (Python):
N = int(input())
S = [input() for i in range(N)]
ac = S.count("AC")
wa = S.count("WA")
tle = S.count("TLE")
re = S.count("RE")
print(f"AC x {ac}")
print(f"WA x {wa}")
print(f"TLE x {tle}")
print(f"RE x {re}")

Solution (Python):
N=int(input())
list1=[]
for i in range(N):
  list1.append(input())
a=list1.count("AC")
w=list1.count("WA")
t=list1.count("TLE")
r=list1.count("RE")
print(f'AC x {a}')
print(f'WA x {w}')
print(f'TLE x {t}')
print(f'RE x {r}')

Solution (Python):
import sys
import collections

sys.setrecursionlimit(10 ** 8)
ini = lambda: int(sys.stdin.readline())
inm = lambda: map(int, sys.stdin.readline().split())
inl = lambda: list(inm())
ins = lambda: sys.stdin.readline().rstrip()
debug = lambda *a, **kw: print("\033[33m", *a, "\033[0m", **dict(file=sys.stderr, **kw))

N = ini()
S = [ins() for _ in range(N)]


def solve():
    c = collections.Counter(S)

    print("AC x {}".format(c["AC"]))
    print("WA x {}".format(c["WA"]))
    print("TLE x {}".format(c["TLE"]))
    print("RE x {}".format(c["RE"]))


solve()

Solution (Python):
N = int(input())
A = []
for i in range(N):
    a = input()
    A.append(a)

cnt1 = 0
cnt2 = 0
cnt3 = 0
cnt4 = 0

print('AC x {}'.format(A.count('AC')))
print('WA x {}'.format(A.count('WA')))
print('TLE x {}'.format(A.count('TLE')))
print('RE x {}'.format(A.count('RE')))

Solution (Python):
N = int(input())

ac = wa = tle = re = 0

for i in range(N):
	s = str(input())
	if s == "AC":
		ac += 1
	elif s == "WA":
		wa += 1
	elif s == "TLE":
		tle += 1
	else:
		re += 1

print("AC x "+str(ac))
print("WA x "+str(wa))
print("TLE x "+str(tle))
print("RE x "+str(re))

Solution (Python):
n = int(input())
h = {}

for i in range(n):
  verdict = input()
  if verdict == 'AC' or verdict == 'TLE' or verdict == 'RE' or verdict == 'WA':
    if verdict in h:
      h[verdict] += 1
    else:
      h[verdict] = 1

for k in ('AC', 'WA', 'TLE', 'RE'):
  if k in h:
    print("%s x %d" % (k, h[k]))
  else:
    print("%s x 0" % k)

Solution (Python):
N=int(input())
S=[input() for _ in range(N)]
ansdic={"AC":0,"WA":0,"TLE":0,"RE":0}
for i in S:
  ansdic[i]+=1
print(f"AC x {ansdic['AC']}")
print(f"WA x {ansdic['WA']}")
print(f"TLE x {ansdic['TLE']}")
print(f"RE x {ansdic['RE']}")

Solution (Python):
from collections import Counter


N = int(input())
S = [input() for _ in range(N)]
C = Counter(S)
for result in ['AC', 'WA', 'TLE', 'RE']:
    print(result + ' x ' + str(C[result]))

Solution (Python):
n = int(input())
s = [str(input()) for _ in range(n)]
for v in ("AC","WA","TLE","RE"):
	print("{0} x {1}".format(v,s.count(v)))

Solution (Python):
from collections import Counter
_, *lst = open(0).read().split()
c = Counter(lst)
func = lambda x: str(c[x]) if x in c else '0'
print('AC x ' + func('AC'))
print('WA x ' + func('WA'))
print('TLE x ' + func('TLE'))
print('RE x ' + func('RE'))

Solution (Python):
N=int(input())
AC=0;WA=0;TLE=0;RE=0

for i in range(N):
    S=str(input())
    if S=='AC':
        AC += 1
    if S=='WA':
        WA += 1
    if S=='TLE':
        TLE += 1
    if S=='RE':
        RE += 1

print('AC x',AC)
print('WA x',WA)
print('TLE x',TLE)
print('RE x',RE)

Solution (Python):
N = int(input())
S = [input() for i in range(N)]

d = {"AC":0, "WA":0, "TLE":0, "RE":0}
for s in S:
    d[s] += 1

print("AC x " + str(d["AC"]))
print("WA x " + str(d["WA"]))
print("TLE x " + str(d["TLE"]))
print("RE x " + str(d["RE"]))

Solution (Python):

from collections import Counter


def main():
    _, *S = open(0).read().split()
    cnt = Counter(S)
    for status in ["AC", "WA", "TLE", "RE"]:
        print(f"{status} x {cnt[status]}")


if __name__ == "__main__":
    main()

Solution (Python):
n=int(input())
ac=int(0)
wa=int(0)
tle=int(0)
re=int(0)

for i in range(n):
    s=input()
    if s=="AC":
        ac+=1
    if s=="WA":
        wa+=1
    if s=="TLE":
        tle+=1
    if s=="RE":
        re+=1
print("AC x {}".format(ac))
print("WA x {}".format(wa))
print("TLE x {}".format(tle))
print("RE x {}".format(re))

Solution (Python):
from collections import defaultdict

N = int(input())

count = defaultdict(int)
for i in range(N):
  s = input()
  count[s] += 1
print("AC x "+str(count['AC']))
print("WA x "+str(count['WA']))
print("TLE x "+str(count['TLE']))
print("RE x "+str(count['RE']))

Solution (Python):
import sys,math,collections
from collections import defaultdict
import math,sys


def file():
	sys.stdin = open('input.py', 'r')
	sys.stdout = open('output.py', 'w') 
	

def get_array():
	l=list(map(int, input().split()))
	return l
def sod(n):
	n,c=str(n),0
	for i in n:	
		c+=int(i)
	return c	

def main():
	
	l=[]

	for _ in range(int(input())):
		s=input()
		l.append(s)
	
	c=collections.Counter(l)
	print('AC','x',c['AC'])
	print('WA','x',c['WA'])
	print('TLE','x',c['TLE'])
	print('RE','x',c['RE'])
	'''n,x=map(int, input().split())
		l=list(map(int, input().split()))
		l.sort()
		for i in range(len(l)):
			if(2*l[i]>x):
				ind=i
				break
		
		l=l[ind:]+l[:ind]
		print(l)
		cures=len(l)
		i,ans=0,0
		print('h')
		while(cures>0):
			print("nz")
			if(x>=l[i]):
				cures-=1
				x=2*l[i]
				i+=1
			else:
				temp=l[i]
				l[i]=l[i]-x

				l[i]=min(2*l[i],temp)
			ans+=1
		print(ans)'''



		







		
		
		











		








if __name__ == '__main__':
    main()

Solution (Python):


n=int(input())



l = []
for i in range(n):
    l += [input()]
ac = l.count('AC')
wa = l.count('WA')
tle = l.count('TLE')
re = l.count('RE')
print(f'AC x {ac}')
print(f'WA x {wa}')
print(f'TLE x {tle}')
print(f'RE x {re}')

Solution (Python):
n= int(input())
lista=[]
ac= 0
wa=0
tle=0
re=0
for x in range(n):
    palavra= input()
    lista.append(palavra)
for x in range(n):
    if lista[x]== 'AC':
        ac+=1
    if lista[x]== 'WA':
        wa+=1
    if lista[x]== 'TLE':
        tle+=1
    if lista[x]== 'RE':
        re+=1
print("AC x", ac)
print("WA x", wa)
print("TLE x",tle )
print("RE x", re)

Solution (Python):
n=int(input())
s=[input() for _ in range(n)]
for t in ["AC","WA","TLE","RE"]:
	print(t, "x", s.count(t))

Solution (Python):
d = {'AC':0, 'WA':0, 'TLE':0, 'RE':0}
for _ in range(int(input())):
	d[input()] += 1
for i in d:
	print(i,'x',d[i])

Solution (Python):
N = int(input())
s = [input() for i in range(N)]
for v in ['AC', 'WA', 'TLE', 'RE']:
    print('{0} x {1}'.format(v, s.count(v)))

Solution (Python):
input_one=int(input())
array=[]
a={"AC":0,"WA":0,"TLE":0,"RE":0}
for i in range(input_one):
    array.append(input())
for i in array:
    if i=="AC":
        a[i]+=1
    elif i=="WA":
        a[i]+=1
    elif i=="TLE":
        a[i]+=1
    elif i=="RE":
        a[i]+=1
    else:
        print()
print("AC x",a["AC"])
print("WA x",a["WA"])
print("TLE x",a["TLE"])
print("RE x",a["RE"])

Solution (Python):
n = int(input())
AC = 0
WA = 0
TLE = 0
RE = 0
for i in range(n):
  e = str(input())
  if e  == "AC":
    AC += 1
  elif e  == "WA":
    WA += 1
  elif e  == "TLE":
    TLE += 1
  else:
    RE += 1
print("AC x "+str(AC))
print("WA x "+str(WA))
print("TLE x "+str(TLE))
print("RE x "+str(RE))

Solution (Python):
import sys
from collections import defaultdict as dd
from collections import deque
from fractions import Fraction as f
from copy import *
from bisect import *	
from heapq import *
from math import *
from itertools import permutations 
 
def eprint(*args):
    print(*args, file=sys.stderr)
zz=1
 

if zz:
	input=sys.stdin.readline
else:	
	sys.stdin=open('input.txt', 'r')
	sys.stdout=open('all.txt','w')
def li():
	return [int(x) for x in input().split()]
def fli():
	return [float(x) for x in input().split()]	
def gi():	
	return [x for x in input().split()]
def fi():
	return int(input())
def swap(a,i,j):
	a[i],a[j]=a[j],a[i]	
def si():
	return list(input().rstrip())	
def mi():
	return 	map(int,input().split())	
def gh():
	sys.stdout.flush()
def graph(n,m):
	for i in range(m):
		x,y=mi()
		a[x].append(y)
		a[y].append(x)
def bo(i):
	return ord(i)-ord('a')
		


tt=1


while tt>0:
	tt-=1
	n=fi()
	d={'AC':0,'WA':0,'TLE':0,'RE':0}
	for i in range(n):
		s=input().rstrip()
		d[s]+=1
	for i in d:
		print(i,"x",d[i])

Solution (Python):
arr = []
n = int(input())
while n > 0:
  arr.append(input())
  n -= 1
print('AC x', arr.count('AC'))
print('WA x', arr.count('WA'))
print('TLE x', arr.count('TLE'))
print('RE x', arr.count('RE'))

Solution (Python):
N = int(input())
S = [input() for _ in range(N)]
a = S.count("AC")
b = S.count("WA")
c = S.count("TLE")
d = S.count("RE")
print("AC x "+str(a))
print("WA x "+str(b))
print("TLE x "+str(c))
print("RE x "+str(d))

Solution (Python):
n = int(input())
inp = {}
for i in range(n):
    a = input()
    if inp.get(a) is None:
        inp[a] = 0
    inp[a] += 1
print(f"AC x {0 if inp.get('AC') is None else inp.get('AC')}")
print(f"WA x {0 if inp.get('WA') is None else inp.get('WA')}")
print(f"TLE x {0 if inp.get('TLE') is None else inp.get('TLE')}")
print(f"RE x {0 if inp.get('RE') is None else inp.get('RE')}")