最赞回答 / 慕无忌4210317
这是一个双重循环,可以这样理解,二维数组是一维数组中每个元素是个盒子,盒子里面还有多个元素.你用第一个for循环是循环每个盒子,用第二个for循环是循环每个盒子里面的元素.?
2020-03-17
最新回答 / 一只叮当
for(int i =0;i < 11;i++){if(i%2!=0){int sum1 += A[i];}else{int sum2 += A[i];}}sum = sum2 -sum1;
2020-03-17
已采纳回答 / 阿政阿
import java.util.Scanner;public class text { public static void main(String[] args) { Scanner sc = new Scanner(System.in); String inputString = sc.nextLine(); String a[] = inputString.split("\\s+"); int[] scores = new int[a.length]; for(int i=0;i&t;s...
2020-03-17
最新回答 / qq_虓弑悳酆_0
int scores[]={......}你的对象是hello不是HelloArrays.sort(scores); if(scores[i]<0||scores[i]>100){建议你还是下个myeclipse编程吧,都是一些低级错误
2020-03-16
最新回答 / lalala铁臂阿童木
package helloWorld;public class notOdd { public static void main(String[] args) { int[] array={25,46,39,75,89,26,100}; System.out.println("输出:"); notOdd hello=new notOdd(); hello.range(array); } public void range(int[] array){ int num=0; for(i...
2020-03-15