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



Sample input:
6
AC
TLE
AC
AC
WA
TLE


Sample output:
AC x 3
WA x 1
TLE x 2
RE x 0

Submission status: Accepted

Solution code:
N = int(input())

L = [0] * 4

for i in range(N):
    S = input()
    if S == 'AC':
        L[0] += 1
    elif S == 'WA':
        L[1] += 1
    elif S == 'TLE':
        L[2] += 1
    else:
        L[3] += 1

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

Submission status: Accepted

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

for k, v in a.items():
    print(f'{k} x {v}')

Submission status: Accepted

Solution code:
n=int(input())
s_list=[]

for i in range(n):
    s_list.append(input())
    

c_0=s_list.count("AC")
c_1=s_list.count("WA")
c_2=s_list.count("TLE")
c_3=s_list.count("RE")

print("AC x",c_0)
print("WA x",c_1)
print("TLE x",c_2)
print("RE x",c_3)

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
n=int(input())
judge={'AC':0, 'WA':0, 'TLE':0, 'RE':0}
for i in range(n):
  j=input()
  judge[j]+=1
for k, v in judge.items():
  print('{0} x {1}'.format(k,v))

Submission status: Accepted

Solution code:
N = int(input())
S = [0] * N
for i in range(N):
    S[i] = input()

count_list = [0]*4
count_list[0] = S.count('AC')
count_list[1] = S.count('WA')
count_list[2] = S.count('TLE')
count_list[3] = S.count('RE')

print('AC x' , count_list[0])
print('WA x' , count_list[1])
print('TLE x' , count_list[2])
print('RE x' , count_list[3])

Submission status: Accepted

Solution code:
from sys import stdin


def readline_from_stdin() -> str:
    return stdin.readline().rstrip


if __name__ == '__main__':
    N = int(input())
    S = [input() for i in range(0, 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"))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())
S = [input() for _ 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')))

Submission status: Accepted

Solution code:
def main():
        N = int(input())
        S = [input() for i in range(N)]

        n_ac = 0
        n_wa = 0
        n_tle = 0
        n_re = 0

        for i in range(N):
                temp = S[i]
                if temp=="AC":
                        n_ac+=1
                elif temp=="WA":
                        n_wa+=1
                elif temp=="TLE":
                        n_tle+=1
                else:
                        n_re+=1

        print("AC x",n_ac)
        print("WA x",n_wa)
        print("TLE x",n_tle)
        print("RE x",n_re)

main()

Submission status: Accepted

Solution code:
N = int(input())
ac = 0
tle = 0
wa = 0
re = 0

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

print("AC x %d" %(ac))
print("WA x %d" %(wa))
print("TLE x %d" %(tle))
print("RE x %d" %(re))

Submission status: Accepted

Solution code:
N = int(input())

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

for i in range(0, N):
    s = input()
    if s == 'AC':
        ac += 1
    elif s == 'WA':
        wa += 1
    elif s == 'TLE':
        tle += 1
    elif s == 'RE':
        re += 1

print(f'AC x {ac}')
print(f'WA x {wa}')
print(f'TLE x {tle}')
print(f'RE x {re}')

Submission status: Accepted

Solution code:
N = int(input())
AC = 0
WA = 0
TLE = 0
RE = 0
for i in range(1, N+1):
    S = 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))

Submission status: Accepted

Solution code:
n=int(input())
S=[0]*4
for i in range(n):
  s=input()
  if s=="AC":
    S[0]+=1
  elif s=="WA":
    S[1]+=1
  elif s=="TLE":
    S[2]+=1
  else:
    S[3]+=1

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

Submission status: Accepted

Solution code:
N = int(input().strip())
A = [input().strip() for i in range(N)]

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')))

Submission status: Accepted

Solution code:
n = int(input())
s = []
for _ in range(n):
  s.append(input())
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")))

Submission status: Accepted

Solution code:
n = int(input())
s = [input() for i in range(n)]

cnt_ac = s.count('AC')
cnt_wa = s.count('WA')
cnt_tle = s.count('TLE')
cnt_re = s.count('RE')

print('AC x %s' % cnt_ac)
print('WA x %s' % cnt_wa)
print('TLE x %s' % cnt_tle)
print('RE x %s' % cnt_re)

Submission status: Accepted

Solution code:
import sys

input = sys.stdin.readline

def main():
    ans = 0
    N = int(input())
    ans = [0, 0, 0, 0]
    S = ['AC', 'WA', 'TLE', 'RE']
    for i in range(N):
        s = input().rstrip('\n')
        ans[S.index(s)] += 1
    print(f'AC x {ans[0]}')
    print(f'WA x {ans[1]}')
    print(f'TLE x {ans[2]}')
    print(f'RE x {ans[3]}')

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
n=int(input())
ac =0
wa=0
tle = 0
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"+" "+str(ac))
print("WA "+"x "+str(wa))
print("TLE "+"x "+str(tle))
print("RE "+"x "+str(re))

Submission status: Accepted

Solution code:
def main():
    n = int(input())
    results = {"AC":0,"WA":0,"TLE":0,"RE":0}
    for i in range(n):
        r = input()
        results[r] += 1
    print("AC x " + str(results["AC"]))
    print("WA x " + str(results["WA"]))
    print("TLE x " + str(results["TLE"]))
    print("RE x " + str(results["RE"]))


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N = int(input())
S = []
for i in range(N):
    S.append(input())

ac = str(S.count("AC"))
wa = str(S.count("WA"))
tle = str(S.count("TLE"))
re = str(S.count("RE"))

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

Submission status: Accepted

Solution code:
N = int(input())
ans = [0, 0, 0, 0]
for i in range(N):
  a = input()
  if a == "AC":
    ans[0] += 1
  elif a == "WA":
    ans[1] += 1
  elif a == "TLE":
    ans[2] += 1
  else:
    ans[3] += 1
print("AC x " + str(ans[0]))
print("WA x " + str(ans[1]))
print("TLE x " + str(ans[2]))
print("RE x " + str(ans[3]))

Submission status: Accepted

Solution code:
def resolve():
    import sys
    input = sys.stdin.readline
    # 整数 1 つ
    n = int(input())
    # 整数複数個
    # a, b = map(int, input().split())
    # 整数 N 個 (改行区切り)
    # N = [int(input()) for i in range(N)]
    # 整数 N 個 (スペース区切り)
    # N = list(map(int, input().split()))
    # 整数 (縦 H 横 W の行列)
    # A = [list(map(int, input().split())) for i in range(H)]

    cnt0 = 0
    cnt1 = 0
    cnt2 = 0
    cnt3 = 0
    for _ in range(n):
        ans = input().rstrip()
        if ans == "AC":
            cnt0 += 1
        elif ans == "WA":
            cnt1 += 1
        elif ans == "TLE":
            cnt2 += 1
        elif ans == "RE":
            cnt3 += 1

    print("AC x " + str(cnt0))
    print("WA x " + str(cnt1))
    print("TLE x " + str(cnt2))
    print("RE x " + str(cnt3))

resolve()

Submission status: Accepted

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

ac=0
wa=0
tle=0
re=0
for i in li:
    if i=="AC":
        ac+=1
    elif i =="TLE":
        tle+=1
    elif i=="WA":
        wa+=1
    else:
        re+=1
print("AC x {}".format(ac))
print("WA x {}".format(wa))
print("TLE x {}".format(tle))
print("RE x {}".format(re))

Submission status: Accepted

Solution code:
def main():
  N = int(input())
  C = [0, 0, 0, 0]
  ANS = ["AC", "WA", "TLE", "RE"]
  for i in range(N):
    s = str(input())
    if s == "AC":
      C[0] += 1
    elif s == "WA":
      C[1] += 1
    elif s == "TLE":
      C[2] += 1
    elif s == "RE":
      C[3] += 1
  for i in range(4):
    print(ANS[i] + " x " + str(C[i]) )
    
if __name__ == "__main__":
  main()

Submission status: Accepted

Solution code:
N = int(input())
S = []
count = [0,0,0,0]
for i in range(N):
    temp = input()
    if temp=="AC":
        count[0]+=1
    elif temp=="WA":
        count[1]+=1
    elif temp=="TLE":
        count[2]+=1
    else:
        count[3]+=1
print("AC x "+str(count[0]))
print("WA x "+str(count[1]))
print("TLE x "+str(count[2]))
print("RE x "+str(count[3]))
# N=map(int,input().split())
# S=list(map(int,input().split()))
# B=list(map(int,input().split()))

Submission status: Accepted

Solution code:
# B
N = int(input())
dct = {'AC': 0, 'WA': 0, 'TLE': 0, 'RE': 0}
for i in range(N):
    s = input()
    dct[s] += 1

for k, v in dct.items():
    print(str(k) + ' x ' + str(v))

Submission status: Accepted

Solution code:
n=int(input())
a=[0]*4
b=""
for i in range(n):
    b=input()
    if b=="AC":
        a[0]+=1
    elif b=="WA":
        a[1]+=1
    elif b=="TLE":
        a[2]+=1
    elif b=="RE":
        a[3]+=1

print("AC","x",a[0])
print("WA","x",a[1])
print("TLE","x",a[2])
print("RE","x",a[3])

Submission status: Accepted

Solution code:
n = int(input())
a = [0 for i in range(4)]
b = ["AC", "WA", "TLE", "RE"]
for i in range(n):
  s = input()
  for j in range(4):
    if s == b[j]:
      a[j] += 1
for i in range(4):
  print(b[i], "x", a[i])

Submission status: Accepted

Solution code:
N = int(input())
AC = 0
WA = 0
TLE = 0
RE = 0
for i in range(N):
    A = input()
    if A == 'AC':
        AC += 1
    elif A == 'WA':
        WA += 1
    elif A == '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))

Submission status: Accepted

Solution code:
n = int(input())
ac,wa,tle,re = 0,0,0,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 "+str(ac))
print("WA x "+str(wa))
print("TLE x "+str(tle))
print("RE x "+str(re))

Submission status: Accepted

Solution code:
N = int(input())

result = {}
for _ in range(N):
  s = input()
  result[s] = result.get(s, 0) + 1

print(f"AC x {result.get('AC', 0)}")
print(f"WA x {result.get('WA', 0)}")
print(f"TLE x {result.get('TLE', 0)}")
print(f"RE x {result.get('RE', 0)}")

Submission status: Accepted

Solution code:
ac = 0
wa = 0
tle = 0
re = 0

n = int(input())
for i in range(n):
  x = input()
  if x=='AC':
    ac = ac+1
  elif x=='WA':
    wa = wa+1
  elif x=='TLE':
    tle = tle+1
  else:
    re = re+1
print('AC'+' x '+str(ac))
print('WA'+' x '+str(wa))
print('TLE'+' x '+str(tle))
print('RE'+' x '+str(re))

Submission status: Accepted

Solution code:
def resolve():
    N = int(input())
    ans = [0,0,0,0]
    for i in range(N):
        S = input()
        if S == 'AC':
            ans[0] += 1
        if S == 'WA':
            ans[1] += 1
        if S == 'TLE':
            ans[2] += 1
        if S == 'RE':
            ans[3] += 1
    print( 'AC x ' + str(ans[0]) )
    print( 'WA x ' + str(ans[1]) )
    print( 'TLE x ' + str(ans[2]) )
    print( 'RE x ' + str(ans[3]) )
resolve()

Submission status: Accepted

Solution code:
#!/usr/bin/env python3


def main():
    N = int(input())
    ac, wa, tle, re = 0, 0, 0, 0

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

    print(f'AC x {ac}')
    print(f'WA x {wa}')
    print(f'TLE x {tle}')
    print(f'RE x {re}')


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
N = int(input())
ls = []
for i in range(N):
  a = input()
  ls.append(a)
AC,WA,TLE,RE = ls.count("AC"), ls.count("WA"), ls.count("TLE"), ls.count("RE")
print(f"AC x {AC}\nWA x {WA}\nTLE x {TLE}\nRE x {RE}")

Submission status: Accepted

Solution code:
def main():
  n = int(input())
  c = [0,0,0,0]
  for i in range(n):
    s = input()
    if s == 'AC':
      c[0] += 1
    elif s == 'WA':
      c[1] += 1
    elif s == 'TLE':
      c[2] += 1
    else:
      c[3] += 1
  print(f'AC x {c[0]}')
  print(f'WA x {c[1]}')
  print(f'TLE x {c[2]}')
  print(f'RE x {c[3]}')
main()

Submission status: Accepted

Solution code:
from collections import Counter

N=int(input())
ans_list=[]
for n in range(N):
    ans_list.append(input())

ans_Counter=Counter(ans_list)

ans_val=['AC','WA','TLE','RE']

for a in ans_val:
    print(a+' x',ans_Counter[a])

Submission status: Accepted

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

for key, value in a_dict.items():
  print(key,"x",value)

Submission status: Accepted

Solution code:
N = int(input())
a = 0
b = 0
c = 0
d = 0

for _ in range(N):
    S = input()
    if S == "AC":
        a += 1
    if S == "WA":
        b += 1
    if S == "TLE":
        c += 1
    if S == "RE":
        d += 1

print("AC x "+str(a))
print("WA x "+str(b))
print("TLE x "+str(c))
print("RE x "+str(d))

Submission status: Accepted

Solution code:
N = int(input())

ans = {}
L = []
for _ in range(N):
	L.append(input())

for l in L:
	if l in ans:
		ans[l] +=1
	else:
		ans[l] = 1
print("AC x " + str(ans["AC"])) if "AC" in ans else print("AC x 0")
print("WA x " + str(ans["WA"])) if "WA" in ans else print("WA x 0")
print("TLE x " + str(ans["TLE"])) if "TLE" in ans else print("TLE x 0")
print("RE x " + str(ans["RE"])) if "RE" in ans else print("RE x 0")

Submission status: Accepted

Solution code:
N = int(input())
S = []
for x in range(N):
    S += [input()]


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')))

Submission status: Accepted

Solution code:
a = int(input())

b = [0,0,0,0]
for i in range(a):
    c = input()
    if c == "AC":
        b[0] += 1
    elif c == "WA":
        b[1] += 1
    elif c == "TLE":
        b[2] += 1
    elif c == "RE":
        b[3] += 1

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

Submission status: Accepted

Solution code:
from collections import Counter
N = int(input())
S = [input() for i in range(N)]
res = Counter(S)
print(f"AC x {res['AC']}")
print(f"WA x {res['WA']}")
print(f"TLE x {res['TLE']}")
print(f"RE x {res['RE']}")

Submission status: Accepted

Solution code:
n=int(input())
a=0
b=0
c=0
d=0

for _ in range(n):
  ji=input()
  if ji=="AC":
    a=a+1
  elif ji=="WA":
    b=b+1
  elif ji=="TLE":
    c=c+1
  else:
    d=d+1
    
print("AC x {}".format(a))
print("WA x {}".format(b))
print("TLE x {}".format(c))
print("RE x {}".format(d))

Submission status: Accepted

Solution code:

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

n = int(input())

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 {}'.format(AC))
print('WA x {}'.format(WA))
print('TLE x {}'.format(TLE))
print('RE x {}'.format(RE))

Submission status: Accepted

Solution code:
from typing import List
N = int(input())
AC = 0
WA = 0
TLE = 0
RE = 0
for i in range(N):
    x = input()
    if(x=='AC'):
        AC += 1
    elif(x=='WA'):
        WA += 1
    elif(x=='TLE'):
        TLE += 1
    else:
        RE += 1

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

Submission status: Accepted

Solution code:
n=int(input())
S=[0,0,0,0]
for i in range(n):
    s=input()
    if s=='AC':
        S[0]+=1
    if s=='WA':
        S[1]+=1
    if s=='TLE':
        S[2]+=1
    if s=='RE':
        S[3]+=1

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

Submission status: Accepted

Solution code:
n = int(input())
s = [input() for _ 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')))

Submission status: Accepted

Solution code:
n = int(input())
s = [input() for i in range(n)]

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

for i in s:
    r_dict[i] += 1

for k, v in r_dict.items():
    print(k +' x ' +str(v))

Submission status: Accepted

Solution code:
N = int(input())

C = { "AC" : 0,
    "WA" : 0,
    "TLE" : 0,
    "RE" : 0}


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

for i, j in C.items():
  print(i,"x", j)

Submission status: Accepted

Solution code:
N=int(input())
S=[input() for _ 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')))

Submission status: Accepted

Solution code:
N=int(input())
data=[input() for i in range(N)]
ac=0
wa=0
tle=0
re=0
for i in range(N):
    if data[i]=="AC":
        ac+=1
    elif data[i]=="WA":
        wa+=1
    elif data[i]=="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))

Submission status: Accepted

Solution code:
N = int(input())

ac = 0
wa = 0
tle = 0
re = 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("AC x {}".format(ac))
print("WA x {}".format(wa))
print("TLE x {}".format(tle))
print("RE x {}".format(re))

Submission status: Accepted

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

Submission status: Accepted

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

a = b = c = d = 0

for i in range(N):
    if S[i] == 'AC':
        a += 1
    elif S[i] == 'WA':
        b += 1
    elif S[i] == 'TLE':
        c += 1
    elif S[i] == 'RE':
        d += 1

print('AC x ' + str(a))
print('WA x ' + str(b))
print('TLE x ' + str(c))
print('RE x ' + str(d))

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
# 標準入力を取得
N = int(input())
S = []
for n in range(N):
    S_n = input()
    S.append(S_n)

# 求解処理
judge = {"AC": 0, "WA": 0, "TLE": 0, "RE": 0}
for s in S:
    judge[s] += 1

# 結果出力
for k, v in judge.items():
    print(k, "x", v)

Submission status: Accepted

Solution code:
N = int(input())
arr = [input() for _ in range(N)]
ans_list =[0]*4

for i in range(N):
    if arr[i] == "AC":
        ans_list[0] += 1
    if arr[i] == "WA":
        ans_list[1] += 1
    if arr[i] == "TLE":
        ans_list[2] += 1
    if arr[i] == "RE":
        ans_list[3] += 1

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

Submission status: Accepted

Solution code:
##a = int(stdin.readline().rstrip())
##b, c = [int(x) for x in stdin.readline().rstrip().split()]
##s = stdin.readline().rstrip()
##a = list(set(b))  重複を削除
##a = list(map(int,[int(x) for x in stdin.readline().rstrip().split()])) a[0, 1, 2, ...]
##a = [[0] * 2 for _ in range(n)]  a[0,0]
##v = [s[i: i+2] for i in range(0, len(s), 2)]
##  s="12345678" を v=["12","34","56","78"] にするイメージ
##s = "".join(list)リストを文字列に変換[""]は区切り文字
##a.sort(key=itemgetter(1))リストをソートできるよ(from operator import itemgetterが必要)
##sort_p = sorted(p) 昇順ソート

# -*- coding: utf-8 -*-
from sys import stdin
from operator import itemgetter
from collections import deque, Counter
import math
import pprint
from functools import reduce
import numpy as np
import random
import bisect
# stdin = open("sample.txt")


MOD = 1000000007
INF = float('inf')
alpha = ["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z"]

def keta(kazu): # 入力されたintを桁ごとに分解，リストで出力
    kazu_str = str(kazu)
    kazu_list = [int(kazu_str[i]) for i in range(0, len(kazu_str))]
    return kazu_list

def gcd(*numbers): # 最小公倍数
    return reduce(math.gcd, numbers)

def combination(m,n): # mCn
    
    if n > m:
        return 'すまん'
    return math.factorial(m) // (math.factorial(m-n) * math.factorial(n))

def pow_k(x,n):  # (x**n)の計算の高速化
    if n == 0:
        return 1
    K = 1
    while n > 1:
        if n % 2 != 0:
            K *= x
        x *= x
        n //= 2
    return K * x

def fact(n): # nの素因数分解の結果を辞書で出力 fuct(24) → {2: 3, 3: 1}
    arr = {}
    temp = n
    for i in range(2,int(n**0.5)+1):
        if temp % i == 0:
            cnt = 0
            while temp % i == 0:
                cnt += 1
                temp //= i
            arr[i] = cnt
    if temp != 1:
        arr[temp] = 1
    if arr == {}:
        arr[n] = 1
    return arr


    
def main():
    n = int(stdin.readline().rstrip())
    kekka = {"AC":0, "WA":0, "TLE":0, "RE":0}
    
    for _ in range(n):
        s = stdin.readline().rstrip()
        kekka[s] += 1
    
    for i,j in kekka.items():
        print(i,"x",j)
        
main()

Submission status: Accepted

Solution code:
n=int(input())
r={"AC":0,"WA":0,"TLE":0,"RE":0}
for i in range(n):
  r[input()]+=1
print("AC x %d" % r["AC"])
print("WA x %d" % r["WA"])
print("TLE x %d" % r["TLE"])
print("RE x %d" % r["RE"])

Submission status: Accepted

Solution code:
N = int(input())
a = 0
b = 0
c = 0
d = 0
for n in range(N):
    s = input()
    if s == 'AC':
        a += 1
    if s == 'WA':
        b += 1
    if s == 'TLE':
        c += 1
    if s == 'RE':
        d += 1

print('AC x ' + str(a))
print('WA x ' + str(b))
print('TLE x ' + str(c))
print('RE x ' + str(d))

Submission status: Accepted

Solution code:
n = int(input())
a=[0]*4
k=['AC','WA','TLE','RE']
for x in range(n):
    s=input()
    if s=='AC':
        a[0]+=1
    if s=='WA':
        a[1]+=1
    if s=='TLE':
        a[2]+=1
    if s=='RE':
        a[3]+=1
z=' x '
for i in range(4):
    print(k[i]+z+str(a[i]))

Submission status: Accepted

Solution code:
ls = {'AC':0, 'WA':0, 'TLE':0, 'RE':0}
n = int(input())
for i in range(n):
    s = input()
    ls[s] += 1
for result in ls:
    print("{} x {}".format(result, ls[result]))

Submission status: Accepted

Solution code:
from collections import Counter

N = int(input())


S = [input() for i in range(N)]

C = 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"]))

Submission status: Accepted

Solution code:
n = int(input())
ac = 0
wa = 0
tle = 0
re = 0
for i in range(n):
    a = input()
    if a == "AC":
        ac += 1
    if a == "WA":
        wa += 1
    if a == "TLE":
        tle += 1
    if a == "RE":
        re += 1
print("AC x " + str(ac))
print("WA x " + str(wa))
print("TLE x " + str(tle))
print("RE x " + str(re))

Submission status: Accepted

Solution code:
from collections import Counter

N = int(input())

li = []

for _ in range(N):
    li.append(input())

a =  Counter(li)
# print(a)

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

Submission status: Accepted

Solution code:
N = int(input())
AC = 0
WA = 0
TLE = 0
RE = 0
for n 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 ' + str(AC))
print('WA x ' + str(WA))
print('TLE x ' + str(TLE))
print('RE x ' + str(RE))

Submission status: Accepted

Solution code:
N = int(input())

dic = {'AC':0, 'WA':0, 'TLE':0, 'RE':0}
for i in range(N):
    s = input()
    dic[s] += 1

print("AC x ", dic['AC'])
print("WA x ", dic['WA'])
print("TLE x ", dic['TLE'])
print("RE x ", dic['RE'])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())
results = [input() for _ in range(N)]

result_map = {'AC': 0, 'WA': 0, 'TLE': 0, 'RE': 0}
for result in results:
    result_map[result] += 1

for result, count in result_map.items():
    print('{} x {}'.format(result, count))

Submission status: Accepted

Solution code:
N = int(input())
ac = 0
wa = 0
tle = 0
re = 0
for i in range(N):
    tmp = input()
    if tmp == 'AC':
        ac += 1
    elif tmp == 'WA':
        wa += 1
    elif tmp == 'TLE':
        tle += 1
    elif tmp == 'RE':
        re += 1
print("AC x", ac)
print("WA x", wa)
print("TLE x", tle)
print("RE x", re)

Submission status: Accepted

Solution code:
N=int(input())
a=[]
d=dict(AC=0, WA=0, TLE=0, RE=0)
for _ in range(N):
  a=input()
  d[a]+=1
for k, v in d.items():
  ans=k+" x "+str(v)
  print(ans)

Submission status: Accepted

Solution code:

def main():
    N = int(input())
    ac, wa, tle, re = 0, 0, 0, 0

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



if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
N = int(input())

result = [0]*4

for _ in range(N):
    S = input()
    if S == 'AC':
        result[0] += 1
    elif S == 'WA':
        result[1] += 1
    elif S == 'TLE':
        result[2] += 1
    else:
        result[3] += 1

print('AC x',result[0])
print('WA x',result[1])
print('TLE x',result[2])
print('RE x',result[3])

Submission status: Accepted

Solution code:
N = int(input())

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

for _ in range(N):
    d[input().strip()] += 1

print(f"AC x {d['AC']}")
print(f"WA x {d['WA']}")
print(f"TLE x {d['TLE']}")
print(f"RE x {d['RE']}")

Submission status: Accepted

Solution code:
N = int(input())
S = list(input() for _ in range(N))

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

for s in S:
    if s == "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)

Submission status: Accepted

Solution code:
N = int(input())
tc_ls = []
for i in range(N):
    tc = input()
    tc_ls.append(tc)

AC = tc_ls.count("AC")
WA = tc_ls.count("WA")
TLE = tc_ls.count("TLE")
RE = tc_ls.count("RE")

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

Submission status: Accepted

Solution code:
n = int(input())

book = {"AC": 0, "WA":0, "TLE":0, "RE":0}
for _ in range(n):
    book[input()] += 1

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

Submission status: Accepted

Solution code:
def main():
	ac_ans = 0
	wa_ans = 0
	tle_ans = 0
	re_ans = 0
	n = int(input())
	for i in range(n):
		t = str(input())
		if t == "AC":
			ac_ans += 1
		elif t == "WA":
			wa_ans += 1
		elif t == "TLE":
			tle_ans += 1
		elif t == "RE":
			re_ans += 1

	print("AC x",ac_ans)
	print("WA x",wa_ans)
	print("TLE x",tle_ans)
	print("RE x",re_ans)

if __name__ == '__main__':
	main()

Submission status: Accepted

Solution code:
n = int(input())
counter = [0 for _ in range(4)]
for _ in range(n):
    s = input()
    if s == "AC":
        counter[0] += 1
    elif s == "WA":
        counter[1] += 1
    elif s == "TLE":
        counter[2] += 1
    elif s == "RE":
        counter[3] += 1
print("AC x " + str(counter[0]))
print("WA x " + str(counter[1]))
print("TLE x " + str(counter[2]))
print("RE x " + str(counter[3]))

Submission status: Accepted

Solution code:
N = int(input())

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

for i in range(N):
  s = input()
  dic[s] += 1
  
for i, j in dic.items():
  print(i, 'x', j)

Submission status: Accepted

Solution code:
def resolve():
    n = int(input())

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

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

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


if 'unittest' not in globals():
    resolve()

Submission status: Accepted

Solution code:
n=int(input())
a=0
w=0
t=0
r=0
for _ in range(n):
  b=input()
  if b=="AC":
    a+=1
  elif b=="WA":
    w+=1
  elif b=="TLE":
    t+=1
  else:
    r+=1
print("AC x %d"%a)
print("WA x %d"%w)
print("TLE x %d"%t)
print("RE x %d"%r)

Submission status: Accepted

Solution code:
from collections import Counter

N = int(input())
S = [input() for _ in range(N)]
s_counter = Counter(S)
print('AC x {}'.format(s_counter['AC']))
print('WA x {}'.format(s_counter['WA']))
print('TLE x {}'.format(s_counter['TLE']))
print('RE x {}'.format(s_counter['RE']))

Submission status: Accepted

Solution code:
N = int(input())
S = []
C = []
for i in range(N):
    S.append(input())

results = ['AC', 'WA', 'TLE', 'RE']
for result in results:
    C.append(S.count(result))
print(f"AC x ",C[0],
"\nWA x ",C[1],
"\nTLE x ",C[2],
"\nRE x ",C[3]
)

Submission status: Accepted

Solution code:
n = int(input())

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

print("AC x %d" %ac)
print("WA x %d" %wa)
print("TLE x %d" %tle)
print("RE x %d" %re)

Submission status: Accepted

Solution code:
n = int(input())
c1 = 0
c2 = 0
c3 = 0
c4 = 0
for i in range(n):
  s = str(input()) 
  if s == "AC":
    c1 += 1
  if s== "WA":
    c2 += 1
  if s == "TLE":
    c3 += 1
  if s == "RE":
    c4 += 1

print("AC x " + str(c1))
print("WA x " + str(c2))
print("TLE x " + str(c3))
print("RE x " + str(c4))