[PYTHON] AtCoder 6th Challenge from Dwango Qualifying Participation Record

AtCoder 6th Challenge from Dwango Qualifying Participation Record

A - Falling Asleep

Break through in 4 minutes. Just write.

N = int(input())

total = 0
p = 0
d = {}
for _ in range(N):
    s, t = input().split()
    t = int(t)
    total += t
    d[s] = total
print(total - d[input()])

B - Fusing Slimes

Defeated.

Recommended Posts

AtCoder 6th Challenge from Dwango Qualifying Participation Record
AtCoder DISCO presents Discovery Channel Code Contest 2020 Qualifying Participation Record
Learning record 11 (15th day) Kaggle participation