13293 - hijklmnop   

Description

You are given the mapping between 1~9 and a set of 9 lowercase english letters.

Then, given a word consisting of characters from 1~9 and the given set of 9 lowercase english letters, try to tranform the word by the given mapping.

 

For example, in the sample input, you are given the string "hijklmnop".

This means the mapping:

1 <-> h, 2 <-> i, 3 <-> j, 4 <-> k, 5 <-> l, 6 <-> m, 7 <-> n, 8 <-> o, 9 <-> p.

Thus, the word "9881" should be transformed to "pooh", while the word "3p6n" should be transformed to "j9m7".

 

Note:

Testcases 1~2: only number to english letter.

Testcase 3: only english letter to number.

Testcases 4~5: no limit.

Input

Input contains two lines:

9 characters — the mapping between 1~9 and a set of 9 lowercase english letters. It's guaranteed that no same letters.

A 4-character word. It's guaranteed that the word contains only those characters from 1 to 9 and the lowercase english letters that appear in the first line of the input.

Output

Output contains only a line, that is, the word after being tranformed.

Sample Input  Download

Sample Output  Download

Tags




Discuss