public static void main(String[] args) { Scanner scanner = new Scanner(System.in); System.out.println("输出上次考试"); int score = scanner.nextInt(); System.out.println("输出本次考试"); int scoreTwo = scanner.nextInt();double num = (double) (scoreTwo - score)*100;double numt = num/(double) score; System.out.printf("本次输出得成绩为,%.2f\n",numt);
Sign in to make a reply
亦轩