Naming Loops in Python

前端 未结 4 2013
旧巷少年郎
旧巷少年郎 2020-12-03 17:32

I recently read this question which had a solution about labeling loops in Java.

I am wondering if such a loop-naming system exists in Python. I have been in a situa

4条回答
  •  时光说笑
    2020-12-03 17:43

    There was a proposal to include named loops in python PEP3136, however, it was rejected with an explanation here. The rejection was mostly due to the rare number of circumstances where code readability would be improved by including this construct.

提交回复
热议问题