日期:2014-05-20 浏览次数:20637 次
public class TestArrays {
public static void main(String [] args) {
int [] islands = new int[4];
int [] index = new int[4];
int y = 0;
int ref;
while (y < 4) {
ref = index[y];
islands[ref]=y;
y=y+1;
System.out.print("island = ");
System.out.println(islands[ref]);
}
}
}