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:
def report(k, r):
    print('{} x {}'.format(k, r[k]))

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

N = int(input().rstrip())
for i in range(N):
    S = input().rstrip()
    ans[S] += 1

report('AC', ans)
report('WA', ans)
report('TLE', ans)
report('RE', ans)

Submission status: Accepted

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

Submission status: Accepted

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

print('AC x ' + str(result.count("AC")))
print('WA x ' + str(result.count("WA")))
print('TLE x ' + str(result.count("TLE")))
print('RE x ' + str(result.count("RE")))

Submission status: Accepted

Solution code:
#-------------------- fast io --------------------
import sys

sys.setrecursionlimit(500005)
stdin = sys.stdin

ns = lambda: stdin.readline().strip()
na = lambda: list(map(int, stdin.readline().split()))
ni = lambda: int(ns())

m = {'AC': 0, 'WA': 0, 'TLE': 0, 'RE': 0}
n = ni()
for i in range(n):
    m[ns()] += 1

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

Submission status: Accepted

Solution code:
def solver(N,S):
    ACs = S.count("AC")
    WAs = S.count("WA")
    TLEs = S.count("TLE")
    REs = S.count("RE")
    print("AC x",ACs)
    print("WA x",WAs)
    print("TLE x",TLEs)
    print("RE x",REs)

N = int(input())
S = []
for i in [0] * N:
    S.append(input())
solver(N,S)

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(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())
d = {'AC': 0, 'WA': 0, 'TLE': 0, 'RE': 0}

for i in range(n):
    st = input()
    d[st] += 1

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

Submission status: Accepted

Solution code:
N = int (input())

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

C0=0 #AC
C1=0 #WA
C2=0 #TLE
C3=0 #RE

for i in range(0,N):
    if S[i]=='AC':
        C0+=1
    elif S[i]=='WA':
        C1+=1
    elif S[i]=='TLE':
        C2+=1
    elif S[i]=='RE':
        C3+=1

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

Submission status: Accepted

Solution code:
n = int(input())
s = [input() for i in range(n)]
z = ['AC','WA','TLE','RE']

for j in z:
    print(j+' x '+str(s.count(j)))

Submission status: Accepted

Solution code:
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('AC x ', ac)
print('WA x ', wa)
print('TLE x ', tle)
print('RE x ', re)

Submission status: Accepted

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

for d1, d2 in d.items():
  print(d1,'x',d2)

Submission status: Accepted

Solution code:
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 ' + 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=["AC","WA","TLE","RE"]
c=[0]*4
for _ in range(n):
  c[s.index(input())]+=1
for s1,c1 in zip(s,c):
  print(f'{s1} x {c1}')

Submission status: Accepted

Solution code:
N = int(input())
ac = 0
wa = 0
tle = 0
re = 0
for _ 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(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())
A = [input() for _ in range(n)]

print("AC x " + str(A.count("AC")))
print("WA x " + str(A.count("WA")))
print("TLE x " + str(A.count("TLE")))
print("RE x " + str(A.count("RE")))

Submission status: Accepted

Solution code:
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")))

Submission status: Accepted

Solution code:
n = int(input())
j = [0,0,0,0]
for i in range(0,n):
    s = input()
    if s == "AC":
        j[0] += 1
    elif s == "WA":
        j[1] += 1
    elif s == "TLE":
        j[2] += 1
    elif s == "RE":
        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]))

Submission status: Accepted

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

ac = wa = re = tle = 0
for i in range(n):
    if s[i] == 'AC':
        ac += 1
    elif s[i] == 'WA':
        wa += 1
    elif s[i] == 'RE':
        re += 1
    else:
        tle += 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())
S = list()
for i in range(N):
    S.append(input())

c0 = 0
c1 = 0
c2 = 0
c3 = 0

for i in S:
  if i == "AC":
    c0 += 1
    
  if i == "WA":
    c1 += 1

  if i == "TLE":
    c2 += 1
    
  if i == "RE":
    c3 += 1
  
  
print("AC x " + str(c0))
print("WA x " + str(c1))
print("TLE x " + str(c2))
print("RE x " + str(c3))

Submission status: Accepted

Solution code:
status = ['AC','WA','TLE','RE']
li = []

N = int(input())
for n in range(N):
  li.append(input())

for s in status:
  print(s,'x',li.count(s))

Submission status: Accepted

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

judge = ['AC', 'WA', 'TLE', 'RE']
count = [0] * 4

for i in range(N):
    letter = S[i]
    ind = judge.index(letter)
    count[ind] += 1

for i in range(len(judge)):
    print(judge[i], "x", str(count[i]))

Submission status: Accepted

Solution code:
n = int(input())

num_AC = 0
num_WA = 0
num_TLE = 0
num_RE = 0

for i in range(n):
    i = input()
    if i == "AC":
        num_AC += 1
    elif i == "WA":
        num_WA += 1
    elif i == "TLE":
        num_TLE += 1
    elif i == "RE":
        num_RE += 1
    

print("AC x " + str(num_AC))
print("WA x " + str(num_WA))
print("TLE x " + str(num_TLE))
print("RE x " + str(num_RE))

Submission status: Accepted

Solution code:
n = int(input())

cnt_ac = 0
cnt_wa = 0
cnt_tle = 0
cnt_re = 0

for i in range(n):
    s = input()
    if s == 'AC':
        cnt_ac += 1
    elif s == 'WA':
        cnt_wa += 1
    elif s == 'TLE':
        cnt_tle += 1
    elif s == "RE":
        cnt_re += 1

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

Submission status: Accepted

Solution code:
Judge = [0,0,0,0]
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'))

Submission status: Accepted

Solution code:
n=int(input())


ac=0
wa=0
tle=0
re=0
for i in range(n) :
    s=str(input())
    if s=="AC" :
        ac=ac+1
    elif s=="WA" :
        wa=wa+1
    elif s=="TLE" :
        tle=tle+1
    else :
        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())
ac,wa,tle,re = 0,0,0,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",ac)
print("WA x",wa)
print("TLE x",tle)
print("RE x",re)

Submission status: Accepted

Solution code:
def solve():
    N = int(input())
    cnt = {}
    for i in range(N):
        result = input()
        cnt[result] = cnt.get(result, 0) + 1
    for result in ("AC", "WA", "TLE", "RE"):
        print("{} x {}".format(result, cnt.get(result, 0)))

if __name__ == "__main__":
    solve()

Submission status: Accepted

Solution code:
N = int(input())
S = [input() for _ in range(N)]
AC = 0
WA = 0
TLE = 0
RE = 0
for i in S:
    if i == 'AC':
        AC += 1
    elif i == 'WA':
        WA += 1
    elif 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:
import numpy as np
n=int(input())
a=np.array([0]*4)
for i in range(n):
    s= str(input())
    if s=='AC':
        a[0]+=1
    elif s=='WA':
        a[1]+=1
    elif s=='TLE':
        a[2]+=1
    elif s=='RE':
        a[3]+=1
print('AC x '+str(a[0]))
print('WA x '+str(a[1]))
print('TLE x '+str(a[2]))
print('RE x '+str(a[3]))

Submission status: Accepted

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

a=0
w=0
t=0
r=0

for i in range(N):
  if S[i] =="AC":
    a+=1
  elif S[i] =="WA":
    w+=1
  elif S[i] =="TLE":
    t+=1
  elif S[i] =="RE":
    r+=1

print("AC x "+ str(a))
print("WA x "+ str(w))
print("TLE x "+ str(t))
print("RE x "+ str(r))

Submission status: Accepted

Solution code:
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)))

Submission status: Accepted

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

print("AC x "+str(L.count('AC'))+
"\nWA x "+str(L.count('WA'))+
"\nTLE x "+str(L.count('TLE'))+
"\nRE x "+str(L.count('RE')))

Submission status: Accepted

Solution code:
N = int(input())

#Ansのi番目がACとかの数
B = ['AC', 'WA', 'TLE', 'RE']
A = []
for i in range(N):
  A.append(input())
for i in range(4):
  print(B[i],'x' ,A.count(B[i]))

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys
from itertools import chain
from collections import Counter

# form bisect import bisect_left, bisect_right, insort_left, insort_right
# import numpy as np


def solve(N: int, S: "List[str]"):
    d = Counter(S)
    for key in ("AC", "WA", "TLE", "RE"):
        print(f"{key} x {d.get(key, 0)}")


def main():
    tokens = chain(*(line.split() for line in sys.stdin))
    # N, S = map(int, line.split())
    N = int(next(tokens))  # type: int
    S = [next(tokens) for _ in range(N)]  # type: "List[str]"
    solve(N, S)


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
N = int(input())
array = [input() for i in range(N)]
count_AC = 0
count_TLE = 0
count_RE = 0
count_WA = 0
for i in array:
    if i == "AC":
        count_AC += 1
    elif i == "TLE":
        count_TLE += 1
    elif i == "RE":
        count_RE += 1
    elif i == "WA":
        count_WA += 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))

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
    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:
#B
N=int(input())
C=[input() for i in range(N)]
AC=C.count('AC')
WA=C.count('WA')
TLE=C.count('TLE')
RE=C.count('RE')
print('AC x {}\nWA x {}\nTLE x {}\nRE x {}'.format(AC, WA, TLE, RE))

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:
n = int(input())

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

for i in range(n):
    a = input()
    dic[a] += 1

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())
s = [input() for _ in range(n)]
dic = {"AC": 0, "WA": 0, "TLE": 0, "RE":0}

for v in s:
  dic[v] += 1

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

Submission status: Accepted

Solution code:
N=int(input())
d=[input() for i in range(N)]
ac=0
wa=0
tle=0
re=0
for i in range(N):
    if d[i]=="AC":
        ac+=1
    elif d[i]=="WA":
        wa+=1
    elif d[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())
C_0 = 0
C_1 = 0
C_2 = 0
C_3 = 0
for _ 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('AC x {}'.format(C_0))
print('WA x {}'.format(C_1))
print('TLE x {}'.format(C_2))
print('RE x {}'.format(C_3))

Submission status: Accepted

Solution code:
N = int(input())

C0 = 0
C1 = 0
C2 = 0
C3 = 0

for i in range(0,N):
  S = str(input())
  if S == 'AC':
    C0 += 1
  elif S == 'WA':
    C1 += 1
  elif S == 'TLE':
    C2 += 1
  elif S == 'RE':
    C3 += 1
    
print('AC x',C0)
print('WA x',C1)
print('TLE x',C2)
print('RE x',C3)

Submission status: Accepted

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

Submission status: Accepted

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


def next_line():
    return input()


def next_int():
    return int(input())


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


def next_int_array_multi_lines(size):
    return [int(input()) for _ in range(size)]


def next_str_array(size):
    return [input() for _ in range(size)]


def main():
    n = next_int()
    str = ["AC", "WA", "TLE", "RE"]
    awtr = [0] * 4
    for _ in range(n):
        s = next_line()
        if s == "AC":
            awtr[0] += 1
        elif s == "WA":
            awtr[1] += 1
        elif s == "TLE":
            awtr[2] += 1
        else:
            awtr[3] += 1
    for i in range(4):
        print(str[i] + " x ", end="")
        print(awtr[i])


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
n = int(input())
ans_ac = 0
ans_wa = 0
ans_tle = 0
ans_re = 0

for i in range(n):
    s = input()
    if s == 'AC':
        ans_ac += 1
    elif s == 'WA':
        ans_wa += 1
    elif s == 'TLE':
        ans_tle += 1
    else:
        ans_re += 1
        
print('AC x '+str(ans_ac))
print('WA x '+str(ans_wa))
print('TLE x '+str(ans_tle))
print('RE x '+str(ans_re))

Submission status: Accepted

Solution code:
n = int(input())
ans_count = [0] * 4
ans = ['AC','WA','TLE','RE']

for s in range(n):
    tmp = input()
    for t in range(4):
        if tmp == ans[t]:
            ans_count[t] += 1

for s in range(4):
    print('%s x %d' % (ans[s],ans_count[s]))

Submission status: Accepted

Solution code:
from collections import Counter

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

print('AC x ' + str(res['AC']))
print('WA x ' + str(res['WA']))
print('TLE x ' + str(res['TLE']))
print('RE x ' + str(res['RE']))

Submission status: Accepted

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

print('AC x ' + str(res.count('AC')))
print('WA x ' + str(res.count('WA')))
print('TLE x ' + str(res.count('TLE')))
print('RE x ' + str(res.count('RE')))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
import bisect as bi
import math
from collections import defaultdict as dd
import heapq
input=sys.stdin.readline
##import numpy as np
#sys.setrecursionlimit(10**7)
mo=10**9+7
def cin():
    return map(int,sin().split())
def ain():            
    return list(map(int,sin().split()))
def sin():
    return input()
def inin():
    return int(input())
##def power(x, y):
##    if(y == 0):return 1
##    temp = power(x, int(y / 2))%mo
##    if (y % 2 == 0):return (temp * temp)%mo 
##    else:
##        if(y > 0):return (x * temp * temp)%mo 
##        else:return ((temp * temp)//x )%mo
##
##for _ in range(inin()):
n=inin()
d=dd(int)
for i in range(n):
    s=sin().strip()
    d[s]+=1
print("AC x",d["AC"])
print("WA x",d["WA"])
print("TLE x",d["TLE"])
print("RE x",d["RE"])

    
    
    
    
    
    
    
    
        
    
    
    
    
    
    
        
        
    
    
    
    


    





##
        
    
    
    
    
    
    
        
        
    
    
    
    


    





##def msb(n):n|=n>>1;n|=n>>2;n|=n>>4;n|=n>>8;n|=n>>16;n|=n>>32;n|=n>>64;return n-(n>>1) #2 ki power
##def pref(a,n,f):             
##    pre=[0]*n
##    if(f==0):         ##from beginning
##        pre[0]=a[0]
##        for i in range(1,n):
##            pre[i]=a[i]+pre[i-1]
##    else:              ##from end
##        pre[-1]=a[-1]
##        for i in range(n-2,-1,-1):
##            pre[i]=pre[i+1]+a[i]
##    return pre
##maxint=10**24 
##def kadane(a,size): 
##    max_so_far = -maxint - 1
##    max_ending_here = 0
##       
##    for i in range(0, size): 
##        max_ending_here = max_ending_here + a[i] 
##        if (max_so_far < max_ending_here): 
##            max_so_far = max_ending_here 
##  
##        if max_ending_here < 0: 
##            max_ending_here = 0   
##    return max_so_far

Submission status: Accepted

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

for i in ["AC", "WA", "TLE", "RE"]:
  print("{} x {}".format(i, v.count(i)))

Submission status: Accepted

Solution code:
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)))
'''

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())
ac = 0
wa = 0
tle = 0
re = 0
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", ac)
print("WA", "x", wa)
print("TLE", "x", tle)
print("RE", "x", re)

Submission status: Accepted

Solution code:
N = int(input())

ACcount = 0 
WAcount = 0
TLEcount = 0
REcount = 0
for i in range(N):
	S=input()

	if S == "AC":
		ACcount = ACcount + 1
	elif S == "WA":
		WAcount = WAcount + 1
	elif S == "TLE":
		TLEcount = TLEcount + 1
	elif S == "RE":
		REcount = REcount + 1

print("AC x", ACcount)
print("WA x", WAcount)
print("TLE x", TLEcount)
print("RE x", REcount)

Submission status: Accepted

Solution code:
from collections import defaultdict

n = int(input())
results = defaultdict(lambda: 0)

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

for judge in ['AC', 'WA', 'TLE', 'RE']:
  print(judge, ' x ', results[judge])

Submission status: Accepted

Solution code:
n=int(input())
count1=0
count2=0
count3=0
count4=0
 
for i in range(n):
  s=input()
  if(s=="AC"):
    count1+=1
  elif(s=="WA"):
    count2+=1
  elif(s=="TLE"):
    count3+=1
  elif(s=="RE"):
    count4+=1
print("AC x",count1)
print("WA x",count2)
print("TLE x",count3)
print("RE x",count4)

Submission status: Accepted

Solution code:
import sys
import numpy as np  # noqa

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines


N = int(readline())

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

for i in range(N):
    s = readline().rstrip().decode()
    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()) 
a = [input() for _ in range(n)] 
b = [0,0,0,0] 
c = ["AC","WA","TLE","RE"]

for i in range(len(c)): 
    for k in range(n): 
        if a[k] == c[i]:
           b[i] += 1

for i in range(len(c)): 
    print(c[i]+" x "+str(b[i]))

Submission status: Accepted

Solution code:
Num = int(input())
AC =0
WA =0
TLE=0
RE =0

for i in range(Num):
  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())
s=[input() for i in range(n)]
for a in ["AC", "WA", "TLE", "RE"]:
    print(f"{a} x {s.count(a)}")

Submission status: Accepted

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

counter = [0, 0, 0, 0]
for i in range(N):
    if judge[i] == "AC":
        counter[0] += 1
    if judge[i] == "WA":
        counter[1] += 1
    if judge[i] == "TLE":
        counter[2] += 1
    if judge[i] == "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())
res = {"AC": 0, "WA": 0, "TLE": 0, "RE": 0}
for _ in range(n):
    seq = input()
    res[seq] += 1

for key in  res.keys():
    print(f"{key} x {res[key]}")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b, c, d =0, 0, 0 , 0
for i in range(int(input())):
    x = input()
    if x == 'AC':
        a += 1
    if x == 'TLE':
        b += 1
    if x == 'RE':
        c += 1
    if x == 'WA':
        d += 1
print('AC x', a)
print('WA x', d)
print('TLE x', b)
print('RE x', c)

Submission status: Accepted

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

Submission status: Accepted

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

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

for i in S:
    if i == 'AC':
        AC += 1
    elif i == 'WA':
        WA += 1
    elif i == '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:
length = int(input())
cnt = {"AC": 0, "WA": 0, "TLE": 0, "RE": 0}

for _ in range(length):
    s = input()
    cnt[s] += 1
    
for s, num in cnt.items():
    print("{} x {}".format(s, num))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())
count_ac, count_wa, count_tle, count_re = 0, 0, 0, 0
for i in range(n):
    s = input()
    if s == "AC":
        count_ac += 1
    if s == "WA":
        count_wa += 1
    if s == "TLE":
        count_tle += 1
    if s == "RE":
        count_re += 1

print("AC x", count_ac)
print("WA x", count_wa)
print("TLE x", count_tle)
print("RE x", count_re)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
Nin = int(input())
a = [input() for i in range(Nin)]

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

for i in range(Nin):
    if a[i] == "AC":
        ac += 1
    elif a[i] == "WA":
        wa += 1
    elif a[i] == "TLE":
        tle += 1
    elif a[i] == "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())
cnt = [0]*4
judge = ["AC","WA","TLE","RE"]
for i in range(N):
    s = input()
    if s=="AC":
        cnt[0]+=1
    elif s=="WA":
        cnt[1]+=1
    elif s=="TLE":
        cnt[2]+=1
    else:
        cnt[3]+=1
for i in range(4):
    print(judge[i],"x",cnt[i])

Submission status: Accepted

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

c0, c1, c2, c3 = 0, 0, 0, 0

for output in a:
    if output == 'AC':
        c0 += 1
    elif output == 'WA':
        c1 += 1
    elif output == 'TLE':
        c2 += 1
    elif output == 'RE':
        c3 += 1
        
        
print('AC x {}'.format(c0))
print('WA x {}'.format(c1))
print('TLE x {}'.format(c2))
print('RE x {}'.format(c3))

Submission status: Accepted

Solution code:
n = int(input())
s_lst = list(str(input()) for _ in range(n))
count_lst = [0, 0, 0, 0]

for i in range(n):
    consequence = s_lst[i]
    if consequence == 'AC':
        count_lst[0] += 1
    elif consequence == 'WA':
        count_lst[1] += 1
    elif consequence == 'TLE':
        count_lst[2] += 1
    else:
        count_lst[3] += 1

consequence_lst = ['AC x {}'.format(count_lst[0]), 'WA x {}'.format(count_lst[1]), 'TLE x {}'.format(count_lst[2]), 'RE x {}'.format(count_lst[3])]

for i in range(4):
    con = consequence_lst[i]
    print(con)

Submission status: Accepted

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

print(f"AC x {res[0]}")
print(f"WA x {res[1]}")
print(f"TLE x {res[2]}")
print(f"RE x {res[3]}")

Submission status: Accepted

Solution code:
n = int(input())
s = [input()for i in range(n)]
c0 = 0
c1 = 0
c2 = 0
c3 = 0
for i in range(n):
    if s[i] == 'AC':
        c0 += 1
    elif s[i] == 'WA':
        c1 += 1
    elif s[i] == 'TLE':
        c2 += 1
    else:
        c3 += 1
print(f'AC x {c0}\nWA x {c1}\nTLE x {c2}\nRE x {c3}')

Submission status: Accepted

Solution code:
n = int(input())
ac = 0
wa = 0
tle = 0
re = 0
for i in range(n):
  k = input().upper()
  if k == 'AC':
    ac +=1
  elif k == 'WA':
    wa +=1
  elif k == 'TLE':
    tle +=1
  elif k == 'RE':
    re +=1
    
print('{} x {}'.format('AC',ac))
print('{} x {}'.format('WA',wa))
print('{} x {}'.format('TLE',tle))
print('{} x {}'.format('RE',re))

Submission status: Accepted

Solution code:
n = int(input())
S = {"AC":0,"WA":0,"TLE":0,"RE":0}

for i in range(n):
  S[input()] += 1

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

Submission status: Accepted

Solution code:
N = int(input())

C0 = C1 = C2 = C3 = 0

for i in range(N):
    S = input()
    if S == "AC":
        C0 += 1
    elif S == "WA":
        C1 += 1
    elif S == "TLE":
        C2 += 1
    elif S == "RE":
        C3 += 1

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

Submission status: Accepted

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

Submission status: Accepted

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

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 ",ac)
print("WA x ",wa)
print("TLE x ",tle)
print("RE x ",re)

Submission status: Accepted

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

for i in range(int(input())):
    ans[input()] += 1

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

Submission status: Accepted

Solution code:
N = int(input())
S = [input() for i in range(N)]
c0, c1, c2, c3 = 0, 0, 0, 0
for i in S:
    if i == 'AC':
        c0 += 1 
    if i == 'WA':
        c1 += 1
    if i == 'TLE':
        c2 += 1
    if i == 'RE':
        c3 += 1
print('AC','x',c0)
print('WA','x',c1)
print('TLE','x',c2)
print('RE','x',c3)

Submission status: Accepted

Solution code:
N = int(input())
S = (input() for i in range(N))
c0, c1, c2, c3 = 0, 0, 0, 0
for i in S:
    if i == 'AC':
        c0 += 1 
    if i == 'WA':
        c1 += 1
    if i == 'TLE':
        c2 += 1
    if i == 'RE':
        c3 += 1
print('AC','x',c0)
print('WA','x',c1)
print('TLE','x',c2)
print('RE','x',c3)

Submission status: Accepted

Solution code:
from collections import *

N=int(input())
S=Counter([input() for _ in range(N)])
a=["AC","WA","TLE","RE"]
[print(x+" x "+str(S[x])) for x in a]

Submission status: Accepted

Solution code:
from collections import Counter

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

counter = Counter(S)

for k in ["AC", "WA", "TLE", "RE"]:
    print(k, "x", counter[k])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline

def inp():
    return(int(input()))

def inpf():
    return(float(input()))


def inps():
    return str(input())



n = inp()
arr= []
cac = 0
cwa = 0
ctle = 0
cra = 0
for i in range(n):
    s = inps().rsplit()[0]
    if s=="AC": cac+=1
    elif s=="WA": cwa+=1
    elif s=="TLE": ctle+=1
    else: cra+=1
c = [cac, cwa, ctle, cra]
s = ["AC x ", "WA x ", "TLE x ", "RE x "]
for i in range(len(s)):
    print(s[i]+str(c[i]))