BASE16 Decoding
Time limit1sMemory limit256 MB
Decode a BASE16 string by converting each pair of hex digits back into its ASCII character.
- Level
Easy1 of 10
- Topics
- String, Implementation
- Solved
- No attempts yet
Problem
BASE16 is an encoding that writes one byte as two hexadecimal digits. Encoding a string S in BASE16 replaces every character of S with its ASCII code, writes that code as two uppercase hexadecimal digits, and joins the results in order. The ASCII code of the character A is 65, which is 41 in hexadecimal.
Given the BASE16 encoding of a string S, recover S and print it.
Input
The first line contains the BASE16 encoding of the string S. S consists only of uppercase letters, lowercase letters, and digits, and its length is at most 50. The encoded line therefore contains only the digits 0 to 9 and the uppercase letters A to F, and its length is even.
Output
Print the string S on the first line.