[Python-ideas] What are the strong use cases for str.rindex()?

Steven D'Aprano steve at pearwood.info
Wed Apr 24 20:11:42 EDT 2019

On Wed, Apr 24, 2019 at 08:59:18AM +0800, 林自均 wrote:
> Hi all,
> Thanks for the explanation. Now I agree that the need for list.rindex() is
> not as common as str.rindex(). In fact, I only need list.rindex() when
> doing some algorithm problems. I guess that doesn't count as real need here.

Of course it's a "real need", but the question is whether it is common 
enough for somebody to do the work if it doesn't affect them personally.

Can you share an example of one of these algorithms?


More information about the Python-ideas mailing list