From the documentation:
char: The char data type is a single 16-bit Unicode character. It has a minimum value of '\ u0000' (or 0) and a maximum value of '\ uffff' (or 65,535 inclusive).
A source
These are just 16-bit unsigned integers.
People reported that if char > 65535 , the result was char % 65536 , so I assume your char c will be -98 % 65536 , which will result in 65536 - 98 = 65438 .
In any case, to be 100% sure, why don't you just give it a try?
UPDATE:
I see that you want to know what the output of System.out.println(char) (for example).
Char and String literals can contain Unicode characters (UTF-16)
A source
So, System.out.println((char)65438) equivalent to System.out.println('\uFF9E') , which, looking at the UTF-16 encoding table ( source ), is a HALFWIDTH KATAKANA VOICED SOUND MARK . It will be printed, but if the font supports this character, one of these fonts is Arial Unicode MS .
source share