How to use "WHILE" | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How to use "WHILE"

How do I use "while"? I tried to use it like this: while True:print("Hello") But it dose not work. I don't know why and I need help!

12th Feb 2019, 11:38 AM
Loix Gamer
Loix Gamer - avatar
1 Answer
+ 5
It is working fine. Time limit can also exceed sometimes because your condition will never become false and it will continue to print hello forever. https://code.sololearn.com/cXtsMJv5JTi2/?ref=app
12th Feb 2019, 11:40 AM
Arushi Singhania
Arushi Singhania - avatar