Reputation: 2674
I'm trying to get Characters from decimal and hex value.
I tried this code.
(char) Integer.parseInt("AE",16)
It displayed a hexadecimal character, namely (R).
Then I tried
(char) Integer.parseInt("65283",32)
That displayed a east asian character, perhaps Chinese.
Can Anyone please explain me, what these numbers (16,32) stand for?
Thanks in advance.
Upvotes: 1
Views: 802
Reputation: 66637
16, 32 represent radix
Parses the string argument as a signed integer in the radix specified by the second argument
and
The characters in the string must all be digits of the specified radix
Upvotes: 3