+ 5
Usually you have to run through a List or Array like this: for(int i = 0; i < array.length; i++){ //Do Stuff } An enhanced for loop is way more comfortable by removing the "CONDITION" as well as the "AFTERTHOUGHT" part of the loop: for(int i : array){ //Do Stuff }
5th Jan 2017, 8:11 PM
Jonas Fallmann
Jonas Fallmann - avatar