n = int(input())
judge = {}
judge['AC'] = 0
judge['WA'] = 0
judge['TLE'] = 0
judge['RE'] = 0

for i in range(n):
    s = input()
    if s == 'AC':
        judge['AC'] += 1
    if s == 'WA':
        judge['WA'] += 1
    if s == 'TLE':
        judge['TLE'] += 1
    if s == 'RE':
        judge['RE'] += 1
for key, value in judge.items():
    print("{} × {}".format(key, value))
        
