Code to Character
Easyjava
Read an integer between 33 and 126 and print the character it represents by casting it to char.
Input: one integer in the range 33..126.
Output: one line — the character with that code.
Example 1
Input
72
Output
H
Example 2
Input
97
Output
a
- 33 <= code <= 126
Hint 1
char c = (char) n; is a narrowing cast from int to char.
Hint 2
Code 65 is 'A', 97 is 'a'.
Casting an int to char is the reverse of char-to-int: the number is interpreted as a character code. 72 maps to 'H', 36 maps to '$'.