Looping in programming languages facilitates the execution of a set of instructions repeatedly while some condition evaluates as true. Java for loop provides a concise way of writing the loop structure. The for statement consumes the initialization, condition, and increment/decrement in one line thereby providing a shorter, easy to debug structure of looping.
1) for loop: for loop provides a concise way of writing the loop structure. Unlike a while loop, a for statement consumes the initialization, condition and increment/decrement in one line thereby providing a shorter, easy to debug structure of looping.
Syntax:
for (initialization condition; testing condition;
increment/decrement)
{
statement(s)
}
Check For loop & other loops in Java: https://www.geeksforgeeks.org/loops-in-java/