Java char: char is 16 bit type and used to represent Unicode characters. Range of char is 0 to 65,536.
publicclass Main {
publicstaticvoid main(String[] args) {
char ch1 = 'a';
char ch2 = 65;
System.out.println("Value of char variable ch1 is :" + ch1);
System.out.println("Value of char variable ch2 is :" + ch2);
}
}
/*
Value of char variable ch1 is :a
Value of char variable ch2 is :A
*/