Loops


Looping constructs are used when we need to repeat a task a number of times or till some condition is met.
A looping construct should have
- an initial condition – which starts the loop
- an increment – which advances the loop
- a termination condition – which helps come out of the loop
The loops used in JAVA language are :
1. do - while
2. while
            3. for 

Comments

Popular posts from this blog

NICOSIA