While loop
Waialua
while loop is looping as long as the condition is true which means why loop will is still low as long
as giving condition is true and it stops when the condition becomes false while loop is very important
and almost all programming languages have why a loop.
I have two primitive loops for.
And while Let's see how.
OK.
Open brackets do try using a loop.
So I will use loop to print I as long as variable light is less than 6.
So Taieb little i equal one twos y a look.
You have to type the key word dwil first then parentheses and put the conditions.
For example while I less than or equal six colon which means I will still looping as long as I is less
than or equal 6.
Make sure the indentation is very important.
Then type your statements or your lack of code such as print variable light and variable lie plus equal
one plus equal one means to add by one each time the loop is loop.
After that try that and turn and see what he did.
As you can see while loop was looping as long as the condition was true and I did buy one each time
was low.
Then it stopped looping when the variable becomes greater than 6 which breaks the condition rule that
you have put in.
OK.
Thank you for watching.