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: 48ms
Memory: 25184kB
Author: 13373882502
In contest: 1300

t,n=map(int,input().split())
dic={}
for t1 in range(t):
    x,y=input().split()
    dic[x]=y
for i in range(n):
    a=input()
    print(dic[a],end=" ")
print()