题解 | #成绩输入输出#
成绩输入输出
http://www.nowcoder.com/practice/eb49750ef0de47168c21761de086d97c
import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc=new Scanner(System.in); int[] a=new int[3]; for(int i=0;i<3;i++) { a[i]=sc.nextInt(); if(i<2) { System.out.print("score"+(i+1)+"="+a[i]+","); } else{ System.out.print("score"+(i+1)+"="+a[i]); } } } }