While loop:
It is pre tested
loop. It is used when we have to execute a part of code in unknown numbers of
times.
Syntax:
while (Expression){
Loop body
}
Properties of while loop:
1. Task of the
expression is to check the condition. Loop will execute until condition is true
otherwise loop will terminate.
2. If any
expression returns zero then condition will false and if it
No comments:
Post a Comment