for / while else doesn't make sense

Michael Selik michael.selik at gmail.com
Sun Jun 12 14:44:53 EDT 2016


On Sun, Jun 12, 2016 at 6:11 AM Steven D'Aprano <
steve+comp.lang.python at pearwood.info> wrote:

> - run the for block
> - THEN unconditionally run the "else" block
>

Saying "unconditionally" is a bit misleading here. As you say, it's
conditioned on completing the loop without break/return/raise.



More information about the Python-list mailing list