You are given a number and a base for a numeral system, both expressed in decimal form. Your task is to convert the number into its representation in the base numeral system.
The first line contains the decimal representation of the number , which can be up to characters long. The second line contains the decimal representation of the base , also up to characters long.
Provide the representation of the number in the base numeral system. If a digit in this system is between and , print the digit directly. If the digit is greater than , enclose its decimal representation in square brackets (as shown in the example).
Example 1