On Wed, Sep 26, 2018, 9:42 AM Tobias Kohn <ko...@tobiaskohn.ch> wrote:

> Although I doubt it will really make it into Python's grammar, I am all +1
> for the idea of having "repeat" as a loop keyword in Python.  Actually, I
> have been using "repeat" as a keyword in Python for quite some time now,
> and found it not only convenient, but also a great help in education.
>
Guido has repeatedly (haha) rejected this proposal [0]. He has written that
he considered it, but decided that in practical code one almost always
loops over data, and does not want an arbitrary number of iterations. The
range object solves this problem.

You might notice that a repeat keyword appears in many graphics-focused
child education languages, but not many "serious" languages.

[0] I remember at least two times, but can't find them with search at the
moment.

>
_______________________________________________
Python-ideas mailing list
Python-ideas@python.org
https://mail.python.org/mailman/listinfo/python-ideas
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to