Key Points :
1] Entry Control loop
The
looping in which the condition is checked just after initilisation are known as
entry
control loops.
The
entry control loops are as follows :
a]
while loop
b]
for loop
1]
Entry Control loop :
The
loop in which the condition is checked just after initilisation are known as
entry
control loops.
The
entry control loops are as follows :
a]
while loop
b]
for loop
a]
while loop :
As
while loop is entry control loop, first initilisation takes place & then
the
condition
is checked & at last the increment / decrement takes place.
Syntax
:
initilisation;
while(Condition)
{
loop
body;
inc/dec;
}
# Note
:
While
loop executes only when the condition is true.
Loop
will exicute repeately until the condition in the while statement become false.
No comments:
Post a Comment