As I am slowly progressing through the java tutorials, I came across java helper classes. The code is
public static void main(String args[]) {
char myLittleChar = 'b';
char myBigChar = Character.toUpperCase(myLittleChar);
System.out.println(myBigChar);
However, it worked the same even when assigning directly to a helper class.
Character c = 'a';
System.out.println(c.toUpperCase(c));
and the same applied for short or float as well.
However, I didn't come across this much in any tutorial, or any sample code, and is declared as int, short etc. Is it considered a bad practice? If so, why?
Thank you.