Specifically, I'm going to have a case where I'm going to be shuffling arrays around like this:
int [] array00 = new int[10]int [] array01 = new int[10]int [] array02 = new int[10]int [] array03 = new int[10]; do stuff with arrays, and every once in a while:array03 = array02array02 = array01array01 = array00array00 = new int[10]
The array that array03 used to point to gets discarded, and array00 gets a new array initialized to zeros. But would it be better to do something like:
int [] tempArray = array03array03 = array02array02 = array01array01 = array00array00 = tempArrayZeroArray(array00) ; iterates through the array setting each element to 0
That way the original arrays are reused, but you have to go through the iteration process to reset array00.
