Python: Sixteen - Deepstash
Python: Sixteen

Python: Sixteen


3 reads

Python: Sixteen

💻 working

Keep reading for FREE

Learning Python: While loops

The way i see it is while loops work like if statements but in a loop. Lets just think about it, if statements need a condition to run the code in its scope,  a while loop only runs the code in its scope if the condition is true, in this case i did a while True, this would technically run for forever and not stop but i put a break in which stops as soon as reaches this point, in the next loop i added a condition which, but in the scope i am removing 1 from x, which eventually then will make the condition false which then stops the while loop cause the condition is false.


3 reads


It's time to
Read like a Pro.

Jump-start your

reading habits

, gather your



remember what you read

and stay ahead of the crowd!

Save time with daily digests

No ads, all content is free

Save ideas & add your own

Get access to the mobile app

2M+ Installs

4.7 App Rating



Keep reading, keep studying, the more you learn the more you change. If you are doing the Python lessons please join this discord channel but please follow the rules


this will explain a little about while loops