import java.util.Scanner; public class Main2 { public static void main(String[] args) { int[] a = new int[5]; int sum=0; Scanner scanner = new Scanner(System.in); for (int i = 0; i < a.length; i++) { a[i] = scanner.nextInt(); sum += a[i]; } for (int i = 0; i < a.length; i++) { System.out.println(a[i]); } System.out.println(sum); } } /* 基础中的基础了,该认真学java了 */