public class Test { public static void main(String[] args) { String name; int age; Scanner in = new Scanner(System.in); System.out.print("请输入您的姓名 :"); name = in.nextLine(); System.out.print("请输入您的年龄 :"); age = in.nextInt(); System.out.println("姓名 :" + name); System.out.println("年龄 : " + age); } }
试着写写
最新推荐文章于 2022-10-12 20:00:20 发布