Back to the basics question
Which one of the 'WHILE' loops below is efficient memory wise
SomeObject someObject;
while (iterator.hasNext()) {
someObject = iterator.next();
}
OR
while (iterator.hasNext()) {
SomeObject someObject = iterator.next();
}