收起
sc.close();写在sc.nextInt();后面呀,你都关闭了,怎么录入
Scanner sc = new Scanner(System.in); System.out.println("12345"); int num = sc.nextInt(); sc.close();
报告相同问题?