Capgemini Interview Question

Explain a Java program using loop