方法一:
public static char toUpperChase(char c) {
return c -= (96 < c && c < 123) ? 32 : 0;
}
方法二:
public static char toUpperChase(char c) {
return c ^= (96 < c && c < 123) ? 32 : 0;
}
方法三:
public static char toUpperChase(char c) {
return Character.toUpperCase(c);
}