public class ExampleApp {
public static void main(String[] args) {
System.out.println("for loop begins.");
// This for loop will print numbers from 1 to 10
for (int i = 1; i <= 10; i++) // this loop will continue as long as the value of i is less than or equal to 10
{
System.out.println("Number: " + i);
}
System.out.println("for loop stopped.");