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
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee=Noneclosed_at=<Date2018-05-04.03:10:36.475>created_at=<Date2018-05-04.03:07:20.656>labels= []
title='4.4. break and continue Statements, and else Clauses on Loops'updated_at=<Date2018-05-04.06:38:23.482>user='https://bugs.python.org/joesatriani'
range function second parameter is excluded. Hence for x in range(2, n): will not execute when n = 2, and "2 is a prime number" will never appear.
Moreover, might need a break in the else block too.
It is intentional that the second argument for range is excluded. This is called an "half-open" range, and it helps avoid off-by-one and signpost errors.
Your comments about break, continue and else don't seem to actually mean anything. Please write in complete English sentences and explain the nature of the supposed bug.
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: