簡(jiǎn)單的代碼
public static void main(String[] args){
?ifss hello =new ifss();
?int[] scores ={91,89,23,64,119,52,73};
?Arrays.sort(scores);
? System.out.println("考試成績(jī)的前三名:");
? int a=0;
? int b=0;
? int c=0;
? for(int i=0;i<scores.length;i++){
?
?
?if(scores[i]>100){
?continue;
?}else if (a<scores[i]){ ? ? ? ?
a=scores[i];
?}
?}
?for(int q=0;q<scores.length;q++){
?if(scores[q]>=a){
continue;
?}else ?if(b<scores[q]){
b=scores[q];
?}
?}
?
?for(int z=0;z<scores.length;z++){
?if(scores[z]>=b){
?continue;
?}else if(c<scores[z]){
c=scores[z];
?}?
?
? }
??
? System.out.println(a);
? System.out.println(b);
? System.out.println(c);
??
??
??
??
??
??
??
??
??
??
? }
??
??
? }
2018-08-20
ifss hello =new ifss(); ?換成?HelloWorld hello =new HelloWorld();
2018-08-20
你創(chuàng)建的是什么類(lèi)?方法應(yīng)該在HelloWorld類(lèi)中運(yùn)行,編譯器找不到你的“ifss ”類(lèi),所以就沒(méi)用
2018-08-13
補(bǔ)充一下:ifss hello =new ifss();這個(gè)沒(méi)用