Description
This method determines whether the specified char value is uppercase.
Syntax
boolean isUpperCase(char ch)
Parameters
Here is the detail of parameters −
ch − Primitive character type.
Return Value
- This method returns true, if the passed character is really an uppercase.
Example
public class Test {
public static void main(String args[]) {
System.out.println(Character.isUpperCase('c'));
System.out.println(Character.isUpperCase('C'));
System.out.println(Character.isUpperCase('\n'));
System.out.println(Character.isUpperCase('\t'));
}
}
This will produce the following result −
Output
false true false false
java_characters.htm