package nihao;
import java.util.Scanner;
public class BaoZhuangLei {
public static void main(String[] args) {
Scanner in=new Scanner(System.in);
System.out.println("请输入大写字母:");
String letter1=in.next();
System.out.println("输出大写字母为"+letter1.toUpperCase());
//此处应用了toUpperCase()方法
System.out.println("请输入小写字母:");
String letter2=in.next();
System.out.println("输出小写字母为"+letter2.toLowerCase());
//此处应用了toLowerCase()方法
}
}
10-15
447
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)