文件名称:6
-
所属分类:
- 标签属性:
- 上传时间:2013-05-31
-
文件大小:1.1kb
-
已下载:0次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
声明一个Average接口,其中约定求平均值的方法;声明多个类实现
Average接口分别给出求平均值的方法实现。例如,在一组数值中,一种算法是全部数值相加后求平均值,另一种算法是,去掉一个最高分和一个最低分,再将总分求平均等。原始成绩以字符串数组的形式在程序中指定:
String s1[]={"67","80","88","82","90","91",}
String s2[]={"67","80","88a","85","a","91"}
用Integer.parseInt("98")转化成整形数据并检查数据格式是否正确-Average declare an interface by which the agreed averaging method declare multiple classes implement Average interfaces are given averaging method. For example, in a set of values, an algorithm is the added value of all the average, another algorithm is to remove a highest and lowest points, and then averaging the other score. Raw scores in the form of an array of strings specified in the program: String s1 [] = {" 67" , " 80" , " 88" , " 82" , " 90" , " 91" ,} String s2 [] = {" 67" , " 80" , " 88a" , " 85" , " a" , " 91" } using Integer.parseInt (" 98" ) into integer data and checks the data in the correct format
Average接口分别给出求平均值的方法实现。例如,在一组数值中,一种算法是全部数值相加后求平均值,另一种算法是,去掉一个最高分和一个最低分,再将总分求平均等。原始成绩以字符串数组的形式在程序中指定:
String s1[]={"67","80","88","82","90","91",}
String s2[]={"67","80","88a","85","a","91"}
用Integer.parseInt("98")转化成整形数据并检查数据格式是否正确-Average declare an interface by which the agreed averaging method declare multiple classes implement Average interfaces are given averaging method. For example, in a set of values, an algorithm is the added value of all the average, another algorithm is to remove a highest and lowest points, and then averaging the other score. Raw scores in the form of an array of strings specified in the program: String s1 [] = {" 67" , " 80" , " 88" , " 82" , " 90" , " 91" ,} String s2 [] = {" 67" , " 80" , " 88a" , " 85" , " a" , " 91" } using Integer.parseInt (" 98" ) into integer data and checks the data in the correct format
(系统自动生成,下载前可以参看下载内容)
下载文件列表
average.java
实验要求.txt
实验要求.txt
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.