I've got a strange issue with int to char conversion. Here's my code :
char a=100;
System.out.println(a);
System.out.println(a+1);
System.out.println();
System.out.println((char)a+1);
System.out.println((char)101);
System.out.println( (char)a+1==(char)101 );
It gave me this output :
d
101
101
e
true
which is definitly strange : two differents output seems to be the same when compared ! Why is it so ? And how to make a+1
beeing seen as a char ?
Thank you for your answer and sorry if there's some english mistakes, it's not my mothertongue.