Start: Jul, 06, 2019 10:00:00
20190706Python程序设计基础培训扩展练习
End: Jul, 17, 2019 12:00:00
Time elapsed:
Time remaining:

Problem_ID: E
Result: Accepted
Time: 47ms
Memory: 25316kB
Author: 13758696008
In contest: 1300

n,m=map(int,input().split())
d={}
for i in range(n):
    a=input().split()
    d[a[0]]=a[1]
for i in range(m):
    a=input()
    print(d[a],end=" ")