完成几个小代码练习?让自己更加强大?学习新知识回顾一下基础? 1.输入数组计算最大值 2.输出数组反向打印 3.求数组平均值与总和 4.键盘输两int,并求总和 5.键盘输三个int,并求最值 /* 要求:输入一组数组,计算出最大值. */ public class cesi{ public static void main (String[] args) { int[] array = {5, 15, 100, 999, 1000}; int max = array[0]; for (int…
总结:对象调用方法,与在main 里直接输出没什么大的区别,少用方法, 乱搞++++ package com.c2; import java.util.Scanner; public class DD { // 求数组的平均值即 :a[i]/a.length public static void main(String[] args) { Scanner c = new Scanner(System.in); int a[] = new int[4]; DD b = new DD(); // D…