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

Submission status: Accepted

Solution code:
def resolve():
    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
        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}")
resolve()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
def input(): return sys.stdin.readline().rstrip()
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
        else:
            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:
def main():
    n = int(input())

    answers = {'AC': 0, 'WA': 0, 'TLE': 0, 'RE': 0}
    for _ in range(n):
        result = input()
        answers[result] += 1
    for key, value in answers.items():
        print(f'{key} x {value}')


if __name__ == '__main__':
    main()

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
N=int(input())

C0, C1, C2, C3=0, 0, 0, 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:
a=int(input())
b=[input() for i in range(a)]
c=0
d=0
e=0
f=0
for i in range(a):
  if b[i]=="AC":
    c=c+1
  if b[i]=="WA":
    d=d+1
  if b[i]=="TLE":
    e=e+1
  if b[i]=="RE":
    f=f+1
print("AC","x",c)
print("WA","x",d)
print("TLE","x",e)
print("RE","x",f)

Submission status: Accepted

Solution code:
n = int(input())
arr = []
for i in range(n):
    c = input()
    arr.append(c)
    
di = {"AC":0,"WA":0,"TLE":0,"RE":0}

for i in arr:
    if i in di:
        di[i] += 1 
    else:
        di[i] = 1 
        
print("AC x " + str(di.get("AC")))
print("WA x " + str(di.get("WA")))
print("TLE x " + str(di.get("TLE")))
print("RE x " + str(di.get("RE")))

Submission status: Accepted

Solution code:
from collections import Counter
n = int(input())
verdicts = Counter([input() for i in range(n)])
for verdict in ["AC", "WA", "TLE", "RE"]:
    print(f"{verdict} x {verdicts[verdict]}")

Submission status: Accepted

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

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

for i in results:
  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:
n = int(input())
results = [input() for i in range(n)]
ac = results.count('AC')
wa = results.count('WA')
tle = results.count('TLE')
re = results.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())
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
  elif S[i] == 'RE':
    c3 += 1
 
print('AC x %d' %c0)
print('WA x %d' %c1)
print('TLE x %d' %c2)
print('RE x %d' %c3)

Submission status: Accepted

Solution code:
n = int(input())
c0 = 0
c1 = 0
c2 = 0
c3 = 0
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
print(f'AC x {c0}')
print(f'WA x {c1}')
print(f'TLE x {c2}')
print(f'RE x {c3}')

Submission status: Accepted

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

N = int(input().split()[0])
s_list = []

for _ in range(N):
    s = input()
    s_list.append(s)

counter = collections.Counter(s_list)

for item in ["AC", "WA", "TLE", "RE"]:
    print(f"{item} x {counter[item]}")

Submission status: Accepted

Solution code:
from collections import defaultdict


def main():
    N = int(input())
    d = defaultdict(int)
    results = ["AC", "WA", "TLE", "RE"]
    for _ in range(N):
        d[input()] += 1

    for r in results:
        print(f"{r} x {d[r]}")


if __name__ == '__main__':
    main()

Submission status: Accepted

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

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

    
print('AC x',i.count('AC'))
print('WA x',i.count('WA'))
print('TLE x',i.count('TLE'))
print('RE x',i.count('RE'))

Submission status: Accepted

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

ac = 0
wa = 0
tle = 0
re = 0
for i in range(n):
    if s[i] == "AC":
        ac+=1
    elif s[i] == "WA":
        wa += 1
    elif s[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:

def main():
    N = int(input())
    d = {"AC":0, "WA":0, "TLE":0, "RE":0}
    for i in range(N):
        d[input()] +=1
    for key, value in d.items():
        print(f"{key} x {value}")
        

if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
N = int(input())
dictionary = dict(AC=0, WA=0, TLE=0, RE=0)
for _ in range(N):
    s = input()
    dictionary[s] += 1

for key in dictionary.keys():
    print('%s x %d'%(key, dictionary[key]))

Submission status: Accepted

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

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

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

Submission status: Accepted

Solution code:
from collections import Counter

N = int(input())

C = Counter()
for _ in range(N):
    C += {input(): 1}

for v in ["AC", "WA", "TLE", "RE"]:
    print(f"{v} x {C[v]}")

Submission status: Accepted

Solution code:
from collections import defaultdict

N = int(input())
dic = defaultdict(int)
for i in range(N):
    S = input()
    dic[S] = 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())
AC = 0
WA = 0
TLE = 0
RE = 0
for n in range(N):
  tmp = input()
  if tmp == "AC":
    AC += 1
  elif tmp == "WA":
    WA += 1
  elif tmp == "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())
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 = ac + 1
  elif d[i] == 'WA':
    wa = wa +1
  elif d[i] == '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())
S = []
for _ in range(N):
    S.append(input())
    
ac = 0
wa = 0
tle = 0
re = 0
for s in S:
    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)

Submission status: Accepted

Solution code:
n = int(input())

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

for i in range(n):
  status = input()
  if status == 'AC':
    ac += 1
  elif status == 'WA':
    wa += 1
  elif status == '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:
num = int(input())

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

for i in range(num):
    k = input()
    if k == "AC":
        ac += 1
    elif k == "WA":
        wa += 1
    elif k == "TLE":
        tle += 1
    elif k == "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())

c = [0, 0, 0, 0]

for query in range(N):
    s = 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

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

Submission status: Accepted

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

print('AC x %d'% status.count("AC"))
print('WA x %d'% status.count('WA'))
print('TLE x %d'% status.count('TLE'))
print('RE x %d'% status.count('RE'))

Submission status: Accepted

Solution code:
n = int(input())
a = []
for _ in range(n):
    a.append(input())
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())
ans=[0,0,0,0]
judge=['AC','WA','TLE','RE']
for i in range(N):
  S=input()
  for j in range(4):
    if S==judge[j]:
      ans[j]+=1
      break

for i in range(4):
  print('{} x {}'.format(judge[i],ans[i]))

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
    elif x == "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 _ in range(N)]

dic = {"AC":0, "WA":0, "TLE":0, "RE":0}
for i in range(N):
    dic[S[i]] += 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:
if __name__ == "__main__":
    N = int(input())
    C0 = 0
    C1 = 0
    C2 = 0
    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(f'AC x {C0}')
    print(f'WA x {C1}')
    print(f'TLE x {C2}')
    print(f'RE x {C3}')

Submission status: Accepted

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

t = ('AC', 'WA', 'TLE', 'RE')
for i in t:
    print(i, 'x', s.count(i))

Submission status: Accepted

Solution code:
n = int(input())
c0 = 0
c1 = 0
c2 = 0
c3 = 0
for _ 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', c0)
print('WA x', c1)
print('TLE x', c2)
print('RE x', c3)

Submission status: Accepted

Solution code:
n = int(input())

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

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

Submission status: Accepted

Solution code:
n = int(input())
s = {"AC":0,"WA":1,"TLE":2,"RE":3}
d=[0]*4
for i in range(n):
    d[s[input()]] += 1
for key in s.keys():
    print(key,"x",d[s[key]])

Submission status: Accepted

Solution code:
if __name__ == '__main__':

	n = int(input())

	S = [0,0,0,0]
	
	for _ in range(n):
		cmd = input()
		if cmd == "AC":
			S[0] += 1
		elif cmd == "TLE":
			S[2] += 1
		elif cmd == "WA":
			S[1] += 1
		else:
			S[3] += 1

	for i in range(4):
		if i == 0:
			print("AC x " + str(S[0]))
		elif i == 1:
			print("WA x " + str(S[1]))
		elif i == 2:
			print("TLE x " + str(S[2]))
		else:
			print("RE x " + str(S[3]))

Submission status: Accepted

Solution code:
n = int(input())
p= []
AC = 0
WA = 0
TLE = 0
RE = 0
 
for i in range(n):
  p.append(input())
  
for j in p :
  if j == "AC":
    AC += 1
  elif j == "WA":
    WA += 1
  elif j == "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:
#init
N = int(input())
S=[input() for i in range(N)]
for word in ['AC', 'WA', 'TLE', 'RE']:
  print('{0} x {1}'.format(word, S.count(word)))

Submission status: Accepted

Solution code:
#init
N = int(input())
S=[]
for _ in range(N):
  S.append(input())
score=[0]*4
for _ in S:
  if _=='AC':
    score[0]=score[0]+1
  if _=='WA':
    score[1]=score[1]+1
  if _=='TLE':
    score[2]=score[2]+1
  if _=='RE':
    score[3]=score[3]+1
    
print('AC x {0}'.format(score[0]))
print('WA x {0}'.format(score[1]))
print('TLE x {0}'.format(score[2]))
print('RE x {0}'.format(score[3]))

Submission status: Accepted

Solution code:
from collections import defaultdict

m = defaultdict(int)

n = int(input())

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

for k in ["AC", "WA", "TLE", "RE"]:
  print(f"{k} x {m[k]}")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())
lst = [0] *4

for i in range(n):
  a = input()
  if a == 'AC':
    lst[0] += 1
  if a == 'WA':
    lst[1] += 1
  if a == 'TLE':
    lst[2] += 1
  if a == 'RE':
    lst[3] += 1
    
print('AC x',lst[0])
print('WA x',lst[1])
print('TLE x',lst[2])
print('RE x',lst[3])

Submission status: Accepted

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

for a in ['AC','WA','TLE','RE']:
    print(a, 'x', S.count(a))

Submission status: Accepted

Solution code:
n=int(input())
c0=0
c1=0
c2=0
c3=0
for i in range(n):
  s=str(input())
  if s=="AC":
    c0+=1
  elif s=="WA":
    c1+=1
  elif s=="TLE":
    c2+=1
  else:
    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())
w =0
x =0
y =0
z =0

for i in range(N):
    s =input()
    if s =='AC':
        w +=1
    elif s == 'WA':
        x +=1
    elif s == 'TLE':
        y +=1
    elif s == 'RE':
        z +=1

print ('AC x '+str(w))
print ('WA x '+str(x))
print ('TLE x '+str(y))
print ('RE x '+str(z))

Submission status: Accepted

Solution code:
import numpy

N = int(input().strip())

grid = []
for i in range(N):
    grid.append(input().strip())

count_array = [0,0,0,0]
for i in grid:
    if i == "AC":
        count_array[0] += 1
    elif i == "WA":
        count_array[1] += 1
    elif i == "TLE":
        count_array[2] += 1
    else:
        count_array[3] += 1

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

Submission status: Accepted

Solution code:
n=int(input())

ans=[]

for i in range(n):
  ans.append(input())
  
def func(ans,moji):
  num=ans.count(moji)
  print(moji,"x",str(num))

mojis=["AC","WA","TLE","RE"]
for moji in mojis:
	func(ans,moji)

Submission status: Accepted

Solution code:
from sys import stdin
from collections import defaultdict
inp = lambda : stdin.readline().strip()

t = int(inp())
d = {"AC":0,"WA":0,"TLE":0,"RE":0}
for _ in range(t):
    d[inp()] += 1

for i, j in d.items():
    print(i, 'x', j)

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())
ac, wa, tle, re = 0, 0, 0, 0
for i in range(N):
    result = input()
    if result == 'AC':
        ac += 1
    elif result == 'WA':
        wa += 1
    elif result == 'TLE':
        tle += 1
    else:
        re += 1
print('AC x %d\nWA x %d\nTLE x %d\nRE x %d' % (ac, wa, tle, re))

Submission status: Accepted

Solution code:
n = int(input())
si = [input() for _ in range(n)]
ans_str = ['AC x', 'WA x', 'TLE x', 'RE x']
ans = [0]*4
for i in range(n):
    if si[i] == 'AC':
        ans[0] += 1
    elif si[i] == 'WA':
        ans[1] += 1
    elif si[i] == 'TLE':
        ans[2] += 1
    elif si[i] == 'RE':
        ans[3] += 1
    
for i in range(4):
    print(ans_str[i], ans[i])

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())
strs = []
for _ in range(n):
    strs.append(input())
print("AC x ", strs.count("AC"))
print("WA x ", strs.count("WA"))
print("TLE x ", strs.count("TLE"))
print("RE x ", strs.count("RE"))

Submission status: Accepted

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

t = ('AC', 'WA', 'TLE', 'RE')
for i in t:
    print(i, 'x', s.count(i))

Submission status: Accepted

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

result = [input().rstrip() for _ 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:
N = int(input())
S = [input() for i 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:
n = int(input())
lst = []
for i in range(n):
	str1 = input()
	lst.append(str1)
print('AC x' , lst.count('AC'))
print('WA x' , lst.count('WA'))
print('TLE x' ,lst.count('TLE'))
print('RE x' , lst.count('RE'))

Submission status: Accepted

Solution code:
n = int(input())
first_list = ['AC', 'WA', 'TLE', 'RE']
list = []
for _ in range(n):
    list.append(input())

for i in first_list:
    print(i, 'x', list.count(i))

Submission status: Accepted

Solution code:
n = int(input())

s={}

s["AC"] = 0
s["WA"] = 0
s["TLE"] = 0
s["RE"] = 0


for i in range(n):
    r = input()
    s[r] += 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:
import sys; input = sys.stdin.readline
n = int(input())
ac, wa, tle, re = 0, 0, 0, 0
for i in range(n):
    a = input().strip()
    if a == 'AC': ac+=1
    elif a == 'WA': wa += 1
    elif a == 'TLE': tle += 1
    elif 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())
cnt1 = 0
cnt2 = 0
cnt3 = 0
cnt4 = 0
for i in range(N):
  S = input()
  if S == 'AC':
    cnt1 += 1
  elif S == 'WA':
    cnt2 += 1
  elif S == 'TLE':
    cnt3 += 1
  else:
    cnt4 += 1
print( 'AC x ' + str(cnt1) )
print( 'WA x ' + str(cnt2) )
print( 'TLE x ' + str(cnt3) )
print( 'RE x ' + str(cnt4) )

Submission status: Accepted

Solution code:
import bisect,collections,copy,heapq,itertools,math,string
import numpy as np
import sys
sys.setrecursionlimit(10**7)

def _S(): return sys.stdin.readline().rstrip()
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())

N = I()
# 頻度 counter
S = [_S() for _ in range(N)]
c = collections.Counter(S)

judge = ['AC', 'WA', 'TLE', 'RE']
for j in judge:
    print(j + ' x ' + str(c[j]))

Submission status: Accepted

Solution code:
import sys
import numpy as np
from math import ceil as C, floor as F, sqrt
from collections import defaultdict as D, Counter as CNT
from functools import reduce as R
 
ALP = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
alp = 'abcdefghijklmnopqrstuvwxyz'
def _X(): return sys.stdin.readline().rstrip().split(' ')
def _S(ss): return tuple(ss) if len(ss) > 1 else ss[0]
def S(): return _S(_X())
def Ss(): return list(S())
def _I(ss): return tuple([int(s) for s in ss]) if isinstance(ss, tuple) else int(ss)
def I(): return _I(S())
def _Is(ss): return list(ss) if isinstance(ss, tuple) else [ss]
def Is(): return _Is(I())

n = I()
ans = D(int)
for _ in range(n):
  s = S()
  ans[s] += 1

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

Submission status: Accepted

Solution code:
s = []
n = int(input())
for i 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())
a = 0
w = 0
t = 0
r = 0

x = [0]*N
for i in range(N):
  x[i] = input()
  if x[i] == "AC":
    a += 1
  elif x[i] == "WA":
    w += 1
  elif x[i] == "TLE":
    t += 1
  else:
    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())
c0 = 0
c1 = 0
c2 = 0
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
    else:
        exit()

print(f"AC x {c0}")
print(f"WA x {c1}")
print(f"TLE x {c2}")
print(f"RE x {c3}")

Submission status: Accepted

Solution code:
N = int(input())

AC = []
WA = []
TLE = []
RE = []
for i in range(N):
  inp = input()
  if inp == "AC":
  	AC.append(1)
  elif inp == "WA":
    WA.append(1)
  elif inp == "TLE":
    TLE.append(1)
  elif inp == "RE":
    RE.append(1)
  
  
print ("AC x {}".format(len(AC)))
print ("WA x {}".format(len(WA)))
print ("TLE x {}".format(len(TLE)))
print ("RE x {}".format(len(RE)))

Submission status: Accepted

Solution code:
n=int(input())
ac=0
wa=0
tle=0
re=0
for m in range(n):
  a=input()
  if a=='AC':
    ac=ac+1
  elif a=='WA':
    wa=wa+1
  elif a=='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:
n = int(input())
s = list(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())
ansAC = 0
ansWA = 0
ansTLE = 0
ansRE = 0
 
for i in range(N):
  S = input()
  if S == "AC":
    ansAC += 1
  elif S == "TLE":
    ansTLE += 1
  elif S == "WA":
    ansWA += 1
  elif S == "RE":
    ansRE += 1
print("AC x " + str(ansAC))
print("WA x " + str(ansWA))
print("TLE x " + str(ansTLE))
print("RE x " + str(ansRE))

Submission status: Accepted

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

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

for i, v in d.items():
    print(f'{i} x {v}')

Submission status: Accepted

Solution code:
s=[input() for _ in range(int(input()))]
def c(b):return str(s.count(b))
x=' x '
n='\n'
a='AC'
w='WA'
t='TLE'
r='RE'
print(a+x+c(a)+n+w+x+c(w)+n+t+x+c(t)+n+r+x+c(r))

Submission status: Accepted

Solution code:
n = int(input())

s = list()
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())
S = [input() for _ 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("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())
s = [str(input()) for i in range(n)]

a = s.count(('AC'))
b = s.count(('WA'))
c = s.count(('TLE'))
d = s.count(('RE'))

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:
n = int(input())
s = list()
for i in range(n):
    s.append(str(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())

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

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

for x, y in d.items():
    print("{0} x {1}".format(x, y))

Submission status: Accepted

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

for i in range(N):
    i = input()
    if i == "AC":
        a += 1
    elif i == "WA":
        b += 1
    elif i == "TLE":
        c += 1   
    elif 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:
N = int(input())
ans = [0]*4
for i in range(N):
    s = input()
    if s == "AC":
        ans[0] += 1
    elif s == "WA":
        ans[1] += 1
    elif s == "TLE":
        ans[2] += 1
    elif s == "RE":
        ans[3] += 1
print("AC x "+ str(ans[0]),"WA x "+ str(ans[1]),"TLE x "+ str(ans[2]),"RE x "+ str(ans[3]),sep = "\n" )

Submission status: Accepted

Solution code:
from sys import stdin
n = int(input())
s = [stdin.readline()[:-1] for i in range(n-1)]
s.append(input())
ans = [0,0,0,0]
temp = ["AC","WA","TLE","RE"]
for i in s:
    if i=="AC":
        ans[0] += 1
    elif i=="WA":
        ans[1] += 1
    elif i=="TLE":
        ans[2] += 1
    else:
        ans[3] += 1
for i in range(4):
    print("{result} x {num}".format(result=temp[i],num=ans[i]))

Submission status: Accepted

Solution code:
from collections import Counter

n = int(input())
results = Counter([input() for _ in range(n)])

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())
list_s = [input() for x in range(0, n)]
list_count = [0, 0, 0, 0]

for si in list_s:
    if si == 'AC': list_count[0] += 1
    elif si == 'WA': list_count[1] += 1
    elif si == 'TLE': list_count[2] += 1
    else: list_count[3] += 1

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

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())
S = [input() for i 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 ' + 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 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())
L=[input() for i in range(n)]
print("AC","x",L.count("AC"))
print("WA","x",L.count("WA"))
print("TLE","x",L.count("TLE"))
print("RE","x",L.count("RE"))

Submission status: Accepted

Solution code:
IN = [input() for i in range(1)]
N = int(IN[0])
INP = [input() for i in range(int(N))]
AC = 0
WA = 0
TLE = 0
RE = 0
i = 0

while i < N:
  if INP[i] == "AC":
    AC = AC + 1
    i = i + 1
  elif INP[i] == "WA":
    WA = WA + 1
    i = i + 1
  elif INP[i] == "TLE":
    TLE = TLE + 1
    i = i + 1
  elif INP[i] == "RE":
    RE = RE + 1
    i = i + 1
  else:
    i = i + 1

print("AC x " + str(AC))
print("WA x " + str(WA))
print("TLE x " + str(TLE))
print("RE x " + str(RE))