/**
* 〈一句话功能简述〉<br>
* 〈数组的各种应用〉
*
* @author abu
* @create 2019/7/10
* @since 1.0.0
*/
public class TestArray2 {
public static void main(String[] args){
//test1 输入n个学生成绩,判断出最大值,并按区间分组
/*
Scanner s = new Scanner(System.in);
System.out.println("一共有几个学生呀?");
int count = s.nextInt();
int maxscore = 0;
int[] scores = new int[count];
System.out.println("请输入" + count + "个学生的成绩");
for(int i = 0; i < count; i ++){
int score =s.nextInt();
scores[i] = score;
if(scores[i] > maxscore){
maxscore = scores[i];
}
}
System.out.println("最高成绩是" + maxscore);
for(int i = 0; i < count; i ++){
char level;
if(scores[i] >= maxscore - 10){
level &#
练习6——array2
最新推荐文章于 2022-02-15 17:47:43 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)