Computer Applications
Write a difference between the functions isUpperCase( ) and toUpperCase( ).
Java Library Classes
ICSE 2018
33 Likes
Answer
| isUpperCase( ) | toUpperCase( ) |
|---|---|
| isUpperCase( ) function checks if a given character is in uppercase or not. | toUpperCase( ) function converts a given character to uppercase. |
| Its return type is boolean. | Its return type is char. |
Answered By
16 Likes
Related Questions
String s1 = "45.50"; String s2 = "54.50"; double d1=Double.parseDouble(s1); double d2=Double.parseDouble(s2); int x= (int)(d1+d2);What is value of x?
Predict the output of the following code snippet:
char ch='B', char chr=Character.toLowerCase(ch); int n=(int)chr-10; System.out.println((char)n+"\t"+chr);State the data type and value of res after the following is executed:
char ch = '9'; res= Character.isDigit(ch);