How To Use The while Statement in Python

Опубликовано: 07 Июнь 2020
на канале: Practical Python Solutions
72
1

The WHILE statement or WHILE loop executes a block of code while a certain condition is true. It’s a little different than the IF statement we discussed earlier. The IF statement evaluates a condition and executes commands based on whether that condition is met, whereas the WHILE statement
creates a continuous loop that is only broken when the condition for the WHILE statement changes.
The WHILE statement is handy to loop through some code for certain patterns. It is used extensively in game programming and when checking the state of a file or connection.


Смотрите видео How To Use The while Statement in Python онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь Practical Python Solutions 07 Июнь 2020, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 72 раз и оно понравилось 1 людям.