Why doesn't this work ie assign each element in the array to 1?
int []iA2 = new int[10];
System.out.println(iA2[0]); //0
for (int place:iA2){
place=1;
}
System.out.println(iA2[1]); // prints 0