0
How for loop works in java?
1 Odpowiedź
+ 3
A for-loop works in Java like it does in many other languages.
You might want to be more specific, though. Java supports with an intialize, condition, and increment section separated by semicolons. That is the type of loop nearly every c/c++-like language supports. Java also supports a for-each type loop that loops through containers using iterators.
More detailed explanation is at: https://docs.oracle.com/javase/tutorial/java/nutsandbolts/for.html