package com.aj;import java.util.*;public class AJ{ public static void main(String[] args){ AJ hello=new AJ(); int[] scores={89,-23,64,91,119,52,73}; for (int i = 0; i < scores.length; i++) { if (scores[i]<0&&scores[i]>100) { continue; } } hello.getarray(scores);} public int[] getarray (int[] scores){ Arrays.sort(scores); System.out.println("考试成绩前三名为:"+Arrays.toString(scores)); return scores; }}
添加回答
举报
0/150
提交
取消