Problems
Number systems
Number systems
Given a nonnegative integer in the m-th system of calculation. Need to bring this number in the k-th system of calculation.
Input data
The input file in the first line contains two numbers m and k (in decimal), the second line - the number for the transfer. 2 ≤ m, k ≤ 36, for submission to the number 10...35 use capital letters A...Z, respectively, the number of bits of the initial number does not exceed 1000.
Output data
Bring in the output file the required number without leading zeros.
Examples
Input example #1
10 36 29234652
Output example #1
HELLO