题解 | #简单错误记录#
简单错误记录
http://www.nowcoder.com/practice/2baa6aba39214d6ea91a2e03dff3fbeb
l=[]
ll=[]
while 1:
try:
shuru1 = input().split('\\')[-1]
wenjian = shuru1.split(' ')[0][-16:]
hang = shuru1.split(' ')[-1]
shuru = wenjian + ' ' + hang
if shuru not in l:
l.append(shuru)
ll.append(1)
else:
ll[l.index(shuru)] += 1
except:
break
for i in l[-8:]:
print(i,ll[l.index(i)])