So, what is the conclusion? I also think reversed(enumerate(some_seq)) will be 
very useful in many cases.
It should:
1) work the same as reversed(tuple(enumerate(...))) for "reversible" objects as 
argument of enumerate,
2) raise TypeError if the object is not reversible.

Or, another option would be adding a "step" keyword argument to enumerate.
Then, reversing enumerate would be much easier, like this:
enumerate(reversed(some_seq), step=-1)
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/BW2XKRZ4TSXCFULCS2EU33LLNMIXAL5T/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to