Need help understanding this while loop - Python discussion
Feb 13, 2024 ... I'm new to while loops, and I don't quite get what's going on in this code from my book: current_number = 1 while current_number <= 5: ...
Feb 13, 2024 ... I'm new to while loops, and I don't quite get what's going on in this code from my book: current_number = 1 while current_number <= 5: ...
Jan 11, 2022 ... so basically, a while loop goes as follows: while expression . The expression should be something that evaluates to true or false, that's what ...
Jun 9, 2022 ... Hello there :kissing_closed_eyes: I was wondering if there is a shorter or more functional way to write “while loops” in situations where ...
Discussions on Python.org. Needing help with a while loop function call.I simply wanted to try to get the functional result of this code on my own before looking at other examples of and polishing this but I’ve hit a roadblock on something probably all together simple. :sweat_smile
Nov 8, 2022 ... A more general piece of advice, your program has way too many code paths. ... On top of plan you may choose to write code by incrementing it.
Using the while loop: List all the presidents whose names do not contain the letter ‘w’.Here’s an example that may help you understand how to use a while-loop with a list. Suppose you want to print each element of a list my_list.
Oct 1, 2023 ... Welcome! Please post code as text not pictures. Its very hard to read the images. See About the Python Help category for how to do this.
Discussions on Python.org. Implement 'do' to simplify coding. Ideas.any loop termination conditions should appear in the code at the point in the code execution where the condition is evaluated on each iteration. while loops offer both of those features
Jan 13, 2024 ... ... code debugger for Python programs. It supports setting (conditional) breakpoints and single stepping at the source line level, i... For example ...
Jan 28, 2023 ... You don't import time , though I suspect that you didn't copy the code exactly as you've been running it (there's a stray < there too).