You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Unclear paragraph in Section 4.5 (else Clauses on Loops) of Tutorial #162770
I find the following, relatively-recent addition to the Tutorial's section on "else Clauses on Loops" (Section 4.5) to be a little unclear:
One way to think of the else clause is to imagine it paired with the if inside the loop. As the loop executes, it will run a sequence like if/if/if/else. The if is inside the loop, encountered a number of times. If the condition is ever true, a break will happen. If the condition is never true, the else clause outside the loop will execute.
The last three sentences of that paragraph are clear and correct - but I am unclear what the author intended to clarify/illustrate using the first two sentences. For example, I do not see how paring the else with the "if" inside the loop would induce an execution sequence like if/if/if/else.
In my own opinion, the explanation of the prior code example is sufficient without this paragraph (or at least the first two sentences of it which I found troublesome to understand).
If I am simply missing something obvious, then I apologize for the nuisance of reviewing this issue.
Activity