foreach statement java code example
Example 1: java for each
//itemset contains variables of type <Data Type>
for(<Data Type> item : itemset) {
//loop
}
Example 2: how to do for each in java
for(int i : alist)
{
i+=1
}
//itemset contains variables of type <Data Type>
for(<Data Type> item : itemset) {
//loop
}
for(int i : alist)
{
i+=1
}