I have a variable of type
String , which contains the following value:
How do I get the output character whose code is the hex value in this line?
Option using Integer.decode method:
String str = "0xF9"; int code = Integer.decode(str); char c = (char)code;
And the output to the screen in one line within the framework, relatively speaking, code golf: