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())
d = {"AC":0, "WA":0,"TLE":0,"RE":0}
for i in range(n):
  c = input()
  d[c]+=1
for k,v in d.items():
  print(k,"x",v)

Submission status: Accepted

Solution code:
"""
https://atcoder.jp/contests/abc173/tasks/abc173_b
"""

import numpy as np

# from numba import jit


# @jit(nopython=True, parallel=False)  # type: ignore
def calc(S: np.ndarray, keys):
    return {key: np.sum(S == key) for key in keys}


def main() -> None:
    keys = ["AC", "WA", "TLE", "RE"]
    N = int(input())
    S = []
    for i in range(N):
        S.append(input())
    result = calc(np.array(S), keys)
    for key in keys:
        print(f"{key} x {result[key]}")


main()

Submission status: Accepted

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

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

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

Submission status: Accepted

Solution code:
s = int(input())

a = 0
b = 0
c = 0
d = 0

for i in range(s):
  ans = input()
  if ans == "AC":
    a += 1
  elif ans == "WA":
    b += 1
  elif ans == "TLE":
    c += 1
  elif ans == "RE":
    d += 1

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

Submission status: Accepted

Solution code:
x=int(input())
lst = []
for i in range (0,x):
    ele=input()

    lst.append(ele)

a=0
b=0
c=0
d=0

for j in range (0,x):
    if(lst[j]=='AC'):
        a=a+1
    elif(lst[j]=='WA'):
          b=b+1

    elif (lst[j] == 'TLE'):
             c=c+1

    elif (lst[j] == 'RE'):
                d=d+1

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

Submission status: Accepted

Solution code:
C0=0
C1=0
C2=0
C3=0
N=int(input())
S=list(range(N))
for i in range(N):
  S[i] = input()
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",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)]

nac = 0
nwa = 0
ntle = 0
nre = 0

for i in s:
    if i == 'AC':
        nac += 1
    if i == 'WA':
        nwa += 1
    if i == 'TLE':
        ntle += 1
    if i == 'RE':
        nre += 1

print("AC x ", nac)
print("WA x ", nwa)
print("TLE x ", ntle)
print("RE x ", nre)

Submission status: Accepted

Solution code:
n = int(input())
a, w, t, r = 0, 0, 0, 0
for i in range(n):
  key = input()
  if key == "AC":
    a += 1
  if key == "WA":
    w += 1
  if key == "TLE":
    t += 1
  if key == "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:
a=int(input())

b=0
c=0
d=0
e=0

for i in range(a):
  name=input()

  if name=='AC':
    b+=1
  elif name=='WA':
    c+=1
  elif name=='TLE':
    d+=1
  elif name=='RE':
    e+=1

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

Submission status: Accepted

Solution code:
N=int(input())
S=[]
for i in range(0, N):
    val = input()
    S.append(val)
ac=S.count('AC')
wa=S.count('WA')
tle=S.count('TLE')
re=S.count('RE')

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

Submission status: Accepted

Solution code:
N = int(input())

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

for i in range(N):
  S = input()
  sc[S] += 1
#
print("AC", " x ", sc["AC"])
print("WA", " x ", sc["WA"])
print("TLE", " x ", sc["TLE"])
print("RE", " x ", sc["RE"])

Submission status: Accepted

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

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

for Si in S:
    answer[Si] += 1

print('AC x ' + str(answer.get('AC')))
print('WA x ' + str(answer.get('WA')))
print('TLE x ' + str(answer.get('TLE')))
print('RE x ' + str(answer.get('RE')))

Submission status: Accepted

Solution code:
from collections import Counter
N = int(input())
S = []
for i in range(N):
  S.append(input())
s = Counter(S)

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())
s = [input() for i in range(N)]
row = ['AC', 'WA', 'TLE', 'RE']
for r in row:
    count = 0
    for col in s:
        if col == r:
            count += 1
    print(r, 'x', count, sep=' ')

Submission status: Accepted

Solution code:
def main():
    N = int(input())
    S = {'AC':0, 'WA':0, 'TLE':0, 'RE':0}
    judge = ''
    for i in range(N):
        judge = input()
        S[judge] += 1

    print('AC x {}'.format(S['AC']))
    print('WA x {}'.format(S['WA']))
    print('TLE x {}'.format(S['TLE']))
    print('RE x {}'.format(S['RE']))


if __name__ == '__main__':
    main()

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
N = int(input())

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

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

for j in list:
  if j == 'AC':
    C0 = C0 + 1
  elif j == 'WA':
    C1 = C1 + 1
  elif j == 'TLE':
    C2 = C2 + 1
  elif j == 'RE':
    C3 = 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())
a=0
b=0
c=0
d=0

for x in range(n):
  k=input()
  if k=="AC":
    a+=1
  elif k=="WA":
    b+=1
  elif k=="TLE":
    c+=1
  else:
    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:
n = int(input()); s = []
for _ in range(n):
  s.append(input())
 
dic = {"AC":0,
       "WA":0,
       "TLE":0,
       "RE":0}

for res in s:
  if res in dic: dic[res] += 1
  
for k in dic:
  print(f"{k} x {dic[k]}")

Submission status: Accepted

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

count_ac=0
count_wa=0
count_tle=0
count_re=0

for i in range(n):
    if s[i]=='AC':
        count_ac+=1
    elif s[i]=='WA':
        count_wa+=1
    elif s[i]=='TLE':
        count_tle+=1
    else:
        count_re+=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())
S = []
for _ 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:
n = int(input())
ac = wa = tle = re = 0
m = [input() for x in range(n)]
for i in range(n):
      if m[i] == "AC":
            ac += 1
      elif m[i] == "WA":
            wa += 1
      elif m[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())
ca=0
cw=0
ct=0
cr=0
for _ in range(N):
  a=input()
  if a=='AC':
    ca+=1
  elif a=='WA':
    cw+=1
  elif a=='TLE':
    ct+=1
  elif a=='RE':
    cr+=1
    
print('AC x',ca)
print('WA x',cw)
print('TLE x',ct)
print('RE x',cr)

Submission status: Accepted

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

N_ac = judge.count('AC')
N_wa = judge.count('WA')
N_tl = judge.count('TLE')
N_re = judge.count('RE')

print('AC x ' + str(N_ac))
print('WA x '+str(N_wa))
print('TLE x '+str(N_tl))
print('RE x '+str(N_re))

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
from collections import Counter
n = int(input())

d = Counter()

for _ in range(n):
    d[input()] += 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 = [input() for i in range(n)]

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:
import sys

def main():

	N = int(input())
	AC = 0
	WA = 0
	TLE = 0
	RE = 0
	
	for _ in range(N):
		s = input()
		if s == "AC" :
			AC = AC+1
		elif s == "WA" :
			WA = WA+1
		elif s == "TLE" :
			TLE = TLE+1
		elif s == "RE" :
			RE = RE+1
		
	print("AC x " + str(AC))
	print("WA x " + str(WA))
	print("TLE x " + str(TLE))
	print("RE x " + str(RE))
		
	
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):
    word = input()
    if word == "AC":
        ac += 1
    elif word == "WA":
        wa += 1
    elif word == "TLE":
        tle += 1
    elif word == "RE":
        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 = [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())
S = [input() for i in range(N)]
C0 = S.count('AC')
C1 = S.count('WA')
C2 = S.count('TLE')
C3 = S.count('RE')
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:
T = int(input())
#T = 1
count = {'AC': 0, 'WA': 0, 'TLE': 0, 'RE': 0}

for _ in range(T):
	count[str(input())] += 1

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

Submission status: Accepted

Solution code:
n = int(input())
a,b,c,d = 0,0,0,0
for i in range(n):
    p = str(input())
    if p == "AC":
        a += 1
    elif p == "WA":
        b += 1
    elif p == "TLE":
        c += 1
    elif p == "RE":
        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:
n=int(input())
j=[]
for i in range(n):
    j.append(str(input()))
print("AC x "+str(j.count("AC")))
print("WA x "+str(j.count("WA")))
print("TLE x "+str(j.count("TLE")))
print("RE x "+str(j.count("RE")))

Submission status: Accepted

Solution code:
import collections
n = int(input())
s = [input() for _ in range(n)]
s_count = collections.Counter(s)
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:
numberotestcase = int(input())
verdicat=[]
for step in range(numberotestcase):
  exp = input().upper()
  verdicat.append(exp)
 
first = verdicat.count('AC')
sec =  verdicat.count('WA')
thir =  verdicat.count('TLE')
fou = verdicat.count('RE')
print('AC x '+str(first))
print('WA x '+str(sec))
print('TLE x '+str(thir))
print('RE x '+str(fou))

Submission status: Accepted

Solution code:

result = ["AC","WA","TLE","RE"]
result_num = [0,0,0,0]


case = input("")
case = int(case)

list = []
A = 0

while A < case:
  inp = input("")
  if inp == result[0] or inp == result[1] or inp == result[2] or inp == result[3]:
    list.append(inp)
    A = A + 1

A = 0
while A < case:
  if list[A] == result[0]:
    result_num[0] = result_num[0] + 1
  elif list[A] == result[1]:
    result_num[1] = result_num[1] + 1
  elif list[A] == result[2]:
    result_num[2] = result_num[2] + 1
  elif list[A] == result[3]:
    result_num[3] = result_num[3] + 1
  A =A + 1

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

Submission status: Accepted

Solution code:
AC = []
WA  = []
TLE = []
RE = []
n = int(input())
for i in range(n):
    s = input()
    if s== 'AC':
        AC.append(s)
    elif s=='WA':
        WA.append(s)
    elif s=='TLE':
        TLE.append(s)
    else:
        RE.append(s)
print(f'AC x {len(AC)}')
print(f'WA x {len(WA)}')
print(f'TLE x {len(TLE)}')
print(f'RE x {len(RE)}')

Submission status: Accepted

Solution code:
n=int(input())
a=[]
c1=c2=c3=c4=0
for i in range (0,n):
    t=input()
    a.append(t)
    if(a[i]=="AC"):
        c1+=1
    elif(a[i]=="WA"):
        c2+=1
    elif(a[i]=="TLE"):
        c3+=1
    else:
        c4+=1
print("AC x ",end="") 
print(c1)
print("WA x ",end="") 
print(c2)
print("TLE x ",end="") 
print(c3)
print("RE x ",end="") 
print(c4)

Submission status: Accepted

Solution code:
N = int(input())
result_list = [''] * N
for i in range(N):
    result_list[i] = input()
print('AC x {}'.format(result_list.count('AC')))
print('WA x {}'.format(result_list.count('WA')))
print('TLE x {}'.format(result_list.count('TLE')))
print('RE x {}'.format(result_list.count('RE')))

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
    else:
        ans[3] += 1
print("AC x ", end = "")
print(ans[0])
print("WA x ", end = "")
print(ans[1])
print("TLE x ", end = "")
print(ans[2])
print("RE x ", end = "")
print(ans[3])

Submission status: Accepted

Solution code:
import math

def a():
    n = int(input())

    print((10000-n)%1000)


def b():
    n = int(input())
    # s = []
    count = [0]*4
    for i in range(n):
        s = input()
        if s == 'AC':
            count[0] += 1
        elif s == 'WA':
            count[1] += 1
        elif s == 'TLE':
            count[2] += 1
        else:
            count[3] += 1
    
    

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



def c():
    print('')



def d():
    print('')


b()

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 {}\nWA x {}\nTLE x {}\nRE x {}'.format(ac,wa,tle,re))

Submission status: Accepted

Solution code:
n = int(input())
res = {"AC": 0, "WA": 0, "TLE": 0, "RE": 0}
for _ in range(n):
    res[input()] += 1
for k, v in res.items():
    print(f"{k} x {v}")

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())
ac,tle,wa,re = 0,0,0,0
for i in range(n):
    s = input()
    if s == "AC":
        ac+=1
    elif s == "TLE":
        tle+=1
    elif s == "WA":
        wa+=1
    elif s == "RE":
        re+=1
print("AC x {a}\nWA x {b}\nTLE x {c}\nRE x {d}".format(a = ac,b = wa, c = tle, d = re))

Submission status: Accepted

Solution code:
N=int(input())
C0=0
C1=0
C2=0
C3=0
for i in range(N):
  C=input()
  if C=="AC":
    C0+=1
  if C=="WA":
    C1+=1
  if C=="TLE":
    C2+=1
  if C=="RE":
    C3+=1
    
print("AC x {0}\nWA x {1}\nTLE x {2}\nRE x {3}".format(C0,C1,C2,C3))

Submission status: Accepted

Solution code:
n=int(input())
s=[input() for _ in range(n)]
print('AC x', end=' ')
print(s.count('AC'))
print('WA x', end=' ')
print(s.count('WA'))
print('TLE x', end=' ')
print(s.count('TLE'))
print('RE x', end=' ')
print(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 = 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:
#!/usr/bin/env python3
#%% for atcoder uniittest use
import sys
input= lambda: sys.stdin.readline().rstrip()
def pin(type=int):return map(type,input().split())
def tupin(t=int):return tuple(pin(t))
def lispin(t=int):return list(pin(t))
#%%code
from collections import defaultdict
def resolve():
    N,=pin()
    a=defaultdict(int)

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

    t=a["AC"]+a["WA"]+a["TLE"]+a["RE"]
    #print(a)
    assert t==N
    print("AC x",a["AC"])
    print("WA x",a["WA"])
    print("TLE x",a["TLE"])
    print("RE x",a["RE"])    
#%%submit!
resolve()

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
n=int(input())
slist=[]
for i in range(n):
  moji=str(input())
  slist.append(moji)
numdic={}
for chr in ["AC","WA","TLE","RE"]:
  numdic[chr]=slist.count(chr)
for chr,val in numdic.items():
  print(chr," x ",val)

Submission status: Accepted

Solution code:
import sys
a = sys.stdin.readlines()

print("AC x " + str(a.count("AC\n")))
print("WA x " + str(a.count("WA\n")))
print("TLE x " + str(a.count("TLE\n")))
print("RE x " + str(a.count("RE\n")))

Submission status: Accepted

Solution code:
N=int(input())
x = [input() for i in range(N)]
A=str(x.count("AC"))
B=str(x.count("WA"))
C=str(x.count("TLE"))
D=str(x.count("RE"))
print("AC x "+A)
print("WA x "+B)
print("TLE x "+C)
print("RE x "+D)

Submission status: Accepted

Solution code:
n = int(input())
Ss = [input() for i in range(n)]
judges = ["AC","WA","TLE","RE"]
from collections import defaultdict
d = defaultdict(int)
for s in Ss:
    d[s] += 1
for j in judges:
    print("{} x {}".format(j,d[j]))

Submission status: Accepted

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

answer = [0 for _ in range(4)]
for i in range(N):
    if S[i] == "AC":
        answer[0]+=1
    elif S[i] == "WA":
        answer[1]+=1
    if S[i] == "TLE":
        answer[2]+=1
    if S[i] == "RE":
        answer[3]+=1

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

Submission status: Accepted

Solution code:
N = int(input())
S = []
count_AC = 0
count_WA = 0
count_TLE = 0
count_RE = 0
for _ in range(N):
  S.append(input())
for i in S:
  if i == "AC":
    count_AC += 1  
  elif i == "WA":
    count_WA += 1    
  elif i == "TLE":
    count_TLE += 1
  elif i == "RE":
    count_RE += 1
  else:
    pass
a = "AC" + " " + "x" + " " + str(count_AC)
b = "WA" + " " + "x" + " " + str(count_WA)
c = "TLE" + " " + "x" + " " + str(count_TLE)
d = "RE" + " " + "x" + " " + str(count_RE)
print(a, b, c, d, sep="\n")

Submission status: Accepted

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

ans = [0]*4
for dat in s:
    if dat == 'AC':
        ans[0] += 1
    elif dat == 'WA':
        ans[1] += 1
    elif dat == 'TLE':
        ans[2] += 1
    elif dat == 'RE':
        ans[3] += 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]}')

Submission status: Accepted

Solution code:
import sys
import math
from collections import defaultdict
from bisect import bisect_left, bisect_right

sys.setrecursionlimit(10**7)
def input():
    return sys.stdin.readline()[:-1]

mod = 10**9 + 7

def I(): return int(input())
def LI(): return list(map(int, input().split()))
def LIR(row,col):
    if row <= 0:
        return [[] for _ in range(col)]
    elif col == 1:
        return [I() for _ in range(row)]
    else:
        read_all = [LI() for _ in range(row)]
        return map(list, zip(*read_all))

#################

N = I()

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

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

Submission status: Accepted

Solution code:
N = int(input())
Ac,Wa,Re,Tle = 0,0,0,0
for i in range(N):
    result = input()
    if result == "AC":
        Ac += 1
    elif result == "WA":
        Wa += 1
    elif result == "RE":
        Re += 1
    else:
        Tle += 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 sys
N = int(input())
A = sys.stdin.readlines()
A = [b.strip() for b in A]
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 = list(input() for _ in range(N))
cntlst = ['AC', 'WA', 'TLE', 'RE']

for i in cntlst:
    print(i, 'x', s.count(i))

Submission status: Accepted

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

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:
n = int(input())
# co=0
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 "+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())
a = []
for i in range(N):
	a.append(input())

count_AC = 0
count_WA = 0
count_TLE = 0
count_RE = 0

for i in range(N):
	if a[i] == 'AC':
		count_AC += 1
	if a[i] == 'WA':
		count_WA += 1
	if a[i] == 'TLE':
		count_TLE += 1
	if a[i] == 'RE':
		count_RE += 1

print('AC x ', end='')
print(count_AC)
print('WA x ', end='')
print(count_WA)
print('TLE x ', end='')
print(count_TLE)
print('RE x ', end='')
print(count_RE)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
from collections import Counter
def main():
    N = int(input())
    cnt_list = []
    for _ in range(N):
        S = input().rstrip()
        cnt_list.append(S)
    cnt_list = Counter(cnt_list)
    keys = {'AC': 0, 'WA': 0, 'TLE': 0, 'RE': 0}
    for k, v in cnt_list.items():
        keys[k] = v
    print('AC', 'x', keys['AC'])
    print('WA', 'x', keys['WA'])
    print('TLE', 'x', keys['TLE'])
    print('RE', 'x', keys['RE'])
if __name__ == "__main__":
    main()

Submission status: Accepted

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

for i in range(4):
    tmp = "{0} x {1}".format(mo[i],lis[i])
    print(tmp)

Submission status: Accepted

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

N_ac = judge.count('AC')
N_wa = judge.count('WA')
N_tl = judge.count('TLE')
N_re = judge.count('RE')

print('AC x ' + str(N_ac))
print('WA x '+str(N_wa))
print('TLE x '+str(N_tl))
print('RE x '+str(N_re))

Submission status: Accepted

Solution code:
import math
def main():
    judge_l = {'AC':0, 'WA':0, 'TLE':0, 'RE':0}
    l = int(input().rstrip())
    for i in range(l):
      judge = input().rstrip()
      judge_l[judge] += 1
    
    print('AC x {}'.format(judge_l['AC']), end='\n')
    print('WA x {}'.format(judge_l['WA']), end='\n')
    print('TLE x {}'.format(judge_l['TLE']), end='\n')
    print('RE x {}'.format(judge_l['RE']), end='')
    
if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
N = int(input())
S = []
word_list = ["AC","WA","TLE","RE"]
for i in range(N):                     
    array = input()
    S.append(array)

for i in range(4):
  print(word_list[i] +" x "+str(S.count(word_list[i])))

Submission status: Accepted

Solution code:
N = int(input())
S = [str(input()) for i in range(N)]
a = S.count("AC")
w = S.count("WA")
t = S.count("TLE")
r = S.count("RE")
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:
import sys
from collections import deque
si = sys.stdin.readline


def main():
    ans = {'AC': 0, 'WA': 0, 'TLE': 0, 'RE': 0}
    n = int(si())
    while n > 0:
        n -= 1
        s = si()[:-1]
        ans[s] += 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']))


if __name__ == '__main__':
    main()

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:
AC="AC"
WA="WA"
TLE="TLE"
RE="RE"
n=int(input())
l=[str(input()) for i in range(n)]
a=(l.count(AC))
w=(l.count(WA))
t=(l.count(TLE))
r=(l.count(RE))
print(f"AC x {a}")
print(f"WA x {w}")
print(f"TLE x {t}")
print(f"RE x {r}")

Submission status: Accepted

Solution code:
from collections import OrderedDict

str = input()
n = int(str)
hoge = OrderedDict()

hoge['AC'] = 0
hoge['WA'] = 0
hoge['TLE'] = 0
hoge['RE'] = 0

for i in range(n):
    str = input()
    a = 1
    if str in hoge:
        a = hoge[str] + 1
    hoge[str] = a

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

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:
import itertools
import functools
import math
from collections import Counter
from itertools import combinations
import re

N = int(input())

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

c = Counter(M)

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

Submission status: Accepted

Solution code:
a=int(input())
dic={}
dic['AC']=0
dic['WA']=0
dic['TLE']=0
dic['RE']=0
for i in range(a):
  s=input()
  dic[s]=dic[s]+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())
a = 0
b = 0
c = 0
d = 0
for i in range(n):
    e = input()
    if e == "AC":
        a += 1
    if e == "WA":
        b += 1
    if e == "TLE":
        c += 1
    if e == "RE":
        d += 1
print("AC x",a)
print("WA x",b)
print("TLE x",c)
print("RE x",d)

Submission status: Accepted

Solution code:
N = int(input())
ac = 0

wa = 0
tle = 0
re = 0
while (N) :
    x = input()
    if x == 'AC':
        ac+=1
    if x == 'WA':
        wa +=1
    if x == 'TLE':
        tle += 1
    if x == 'RE':
        re += 1
    N-=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())
stuff = {'AC':0, 'WA':0, 'TLE':0, 'RE':0}
for i in range(N):
  a = input()
  stuff[a] = stuff[a]+1
for v in stuff:
  print(str(v)+str(" x ")+str(stuff[v]))

Submission status: Accepted

Solution code:
N = int(input())
S = [input() for _ in range(N)]
C0 = C1 = C2 = 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',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)]

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

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

Submission status: Accepted

Solution code:
N = int(input())
c0=[]
c1=[]
c2=[]
c3=[]
for i in range(N):
    S = input()
    if S == "AC":
        c0.append(S)
    elif S == "WA":
        c1.append(S)
    elif S == "TLE":
        c2.append(S)
    elif S == "RE":
        c3.append(S)

print("AC","x",len(c0))
print("WA","x",len(c1))
print("TLE","x",len(c2))
print("RE","x",len(c3))

Submission status: Accepted

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

a = 0
b = 0
c = 0
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
    else:
        d += 1

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

Submission status: Accepted

Solution code:
N=int(input())
S = []
for _ in range(N):
    S.append(input())
A=S.count('AC')
W=S.count('WA')
T=S.count('TLE')
R=S.count('RE')
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:
tle,ac,wa,re = 0,0,0,0
for _ in range (int(input())):
    n = input()
    if n == 'TLE':
        tle+=1
    elif n=='AC':
        ac+=1
    elif n=='RE':
        re+=1
    else:
        wa+=1
print("AC x ",ac)
print("WA x ",wa)
print("TLE x ",tle)
print("RE x ",re)

Submission status: Accepted

Solution code:
tc = int(input())

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

for t in range(tc):
  r = input()
  if r == "AC":
    ac += 1
  elif r == "WA":
    wa += 1
  elif r == "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))