Loop in python (while)

There are 3 main loop available in pyhton,

1. While loop

2. For loop

3. Nested loop

While loop

While loop is execute until the condition is tru.

Syntax :

While condition :

Statement

Ex:-

i =1

While i<10:

print(i)

i = i+1

O/p :-

1

2

3

4

5

6

7

8

9

That’s the basic of while loop. We will be see about advanced of while loop and about other loop.

If i do any mistake then please inform me.. I’m try to don’t write any miss word.

My gmail. :- rajnandankr845418@gmail.com

https://cyberher.blogspot.com/?m=1

Leave a Comment